Open MelGrubb opened 8 months ago
Hi @MelGrubb this works for me
Hi @MelGrubb this works for me
Ah, I'm doing GraphQL queries and the UI is slightly different for those. There's a separate "variables" tab there. Those are the ones I need to reference in the assertions.
In the Assert tab, I can already make use of environment variables, but there is no way to reference the values from the "Variables" tab. For example, if I have a variable called "id", I'd like to be able to assert that its value appears in the body of the response. Maybe my query tries to retrieve a particular user record. I'd like to assert that the "id" value on the response matches what I asked for. This example is highly simplified, of course.
I'm not sure what that syntax would look like, though. Would it use the same double curly braces? Would the variable name need a prefix of some sort like
{{vars.id}}
and how would you prevent collisions with environment variables other than by saying "don't start your variables with "vars""?