ssannandeji / Zenject-2019

Dependency Injection Framework for Unity3D
MIT License
2.53k stars 366 forks source link

Fix running play-mode tests in player #673

Open haraldreingruber opened 4 years ago

haraldreingruber commented 4 years ago

I was not able to run play-mode tests using the Zenject.SceneTestFixture in a player (instead of in the Editor) until I removed the restriction to the Editor platform for the Zenject-TestFramework asmdef. It makes kind of sense, as it will be running on other platforms, not in the Editor.

I guess the reason for having it there is to prevent Unity from including the test framework in the actual builds. I think this can be achieved as well by adding the "UNITY_INCLUDE_TESTS" constraint. Could you double-check if that works for you?