Search Issue Tracker

Won't Fix

Votes

0

Found in [Package]

Issue ID

1228933

Regression

Yes

Script compiling stops when Editor tests get interrupted during exectuion

Package: Test-Framework

-

After running some Editor Tests and interrupting them, the script compilation fails to get triggered.

Repro steps:
- download this simple repro project
- Run the Editor tests.
- Notice that the tests fail and also that the Editor never exits Play Mode
- Now open a script and try to modify it in any way (add a random bracket and save)
- Go back into the Editor and try to trigger a recompile

Expected result:
- the Editor should trigger a compilation and an error should appear in the console
Actual result:
- nothing happens.

Only after restarting the editor and re-importing the script will the Editor compile it again.
Reproducible with: \
2019.1 and Test Runner Version 0.0.4
2019.2 and Test Runner Version 1.1.13
2019.3 and Test Runner Version 1.1.13
2020.1 and Test Runner Version 1.1.13
2020.2 and Test Runner Version 1.1.13
Cannot reproduce in
18.4 and Test Runner version 0.0.4

  1. Resolution Note:

    It is strongly recommended in general that any action taken by a test is also cleaned up afterwards. So if a test is entering playmode, then it is recommended to put a ExitPlayMode call in a UnityTearDown, to ensure that the test exits playmode, even if it fails. Without this, any other tests executed afterwards would execute inside playmode, which can give unexpected results.

    A workaround for the compilation issue is to exit playmode manually, if you ever find a test that leaves the editor inside playmode .After exiting playmode (by pressing the play button) any scripts can be edited again.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.