Playwright · Middle · Question 23 of 75

How do you pass a value like a user role through project options?

Show the answer

Correct answer: Declare an option fixture and set it in each project's use

Explanation

Option fixtures ({ option: true }) have defaults that projects override, so one test suite can run with different roles or tenants.

Further reading

Problem with a question

Playwright · Middle · question 23

Test yourself

Take the Playwright · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz