https://promptfoo.dev/ logo
Question: sharing vars between tests
# ❓|questions
u
If I have a yaml file dedicated to just test cases, is there a way to share the vars for all of the tests and just override the query for each test?
i
if I am understanding correctly, I think you could use
defaultTest
in the main config. Something like this:
Copy code
yaml
defaultTest:
  vars:
    # These vars are applied to every test
    foo1: bar
    foo2: bar

tests: tests.yaml