fresh-sandwich-8289
01/31/2023, 5:42 PM[
{
"name": "Should get 2 actions",
"type": "case",
"test_config": {
"method": "GET",
"endpoint": "/actions",
"query_parameters": {
"limit": 2
}
},
"expected": {
"status_code": 200
}
},
...
]
Then, a fixture called cases.json specifies which fixtures are needed to run:
["actions", "users", etc]
All of this is to allow teams to only write fixtures for their endpoints, and our CI process compiles the required parts and executes the desired test cases.
I'm struggling to find a proper strategy to load the fixtures.
Using the cy.fixture command ties me to run it inside an it() block and that is complicating things and leading me to nasty let workarounds...
Do you have any suggestion? Should I load the json files from the FS using cy.task?
Thanks in advancegray-kilobyte-89541
01/31/2023, 6:04 PMfresh-sandwich-8289
01/31/2023, 6:06 PM