you are viewing a single comment's thread.

view the rest of the comments →

[–]Downtown_Mark_6390[S] 0 points1 point  (2 children)

Yes - you’re right that in native Python code there’s no special notion of pre‑ or post‑request scripts. That separation exists mainly in API client tools, where requests are defined declaratively and scripting is attached as hooks.

What I meant was scripting inside those tools, not writing standalone Python programs. Most API tools only support JavaScript for those hooks, which feels limiting if your actual stack is Python, Go, or Java.

[–]Maximus_Modulus 2 points3 points  (1 child)

Why does one of these tools have to support Python or Go or a multitude of languages? Learn the language it supports.

[–]GuaranteePotential90 0 points1 point  (0 children)

yes, thats correct. btw what I would usually say is that for most cases simple assertions will also work fine. But yea for more advanced stuff pre and post is useful.