I have some tests that I need to run against different settings that can’t be changed in PlayMode.
These settings are currently (I might need others):
color space
XR rendering mode
Ideally, I’d like to have the ability to tell a specific test to leave playmode, change some setting, re-enter playmode and run the test. Is that possible? Or is there a workaround that doesn’t involve “change settings manually, then run the tests”?
Hm, that sounds it would basically turn the Play Mode tests to Edit Mode tests with hacky playmode then? I see… doesn’t sound ideal. But nice workaround, thanks.
@fherbst are these settings modifiable via some editor API?
if they are, you can basically create a play mode test that will set the required settings before it executes, then restore them to what they were as the test completes.
The test itself should not take care of exiting playmode and running the next test in line.
They will not be changed at runtime. You will have a bunch of tests. As a pre-step for each one of them, you will call this AOI to set whatever settings u need, and then run the test.
Hm, that sounds good, but I’m not sure I understand - would this only work for running individual tests? I’d need it to work with “Run All”.
(I’ll test it out)
re-thinking this approach, it will enter play mode only once and run all tests, so it does not achieve what you want.
Are you sure these settings cannot be modified during play mode ?