Unity Issue Tracker - Failed test because of timeout returns assertion failure message instead of timeout message
Fixed
DSTR-469
Failed test because of timeout returns assertion failure message instead of timeout message
Package: Test-Framework
UnityTest
Timeout
Fixed
1.4.X
1.4.2
Won't Fix
2.0.X
1.1.X
Won't do any 2.0 fixes, 2.0 is never going to be released
This issue will only be fixed in the 1.4 release of UTF
How to reproduce:
1. Open the attached “TimeoutUnityTest.zip” project
2. In the Test Runner window expand “Test Run” > “Tests.dll” > “My Test”
3. Right-click on TestBug and press “Run”
Expected result: Test fails with message “Timeout value of 1234ms was exceeded”
Actual result: Test fails with message “Expected: 1 But was: 0”
When test timeouts, the timeout message appears if the assertion would have returned true, otherwise the failed test message shows assertion results
Failed test message:
TestBug (1.256s)
—
Expected: 1
But was: 0
—
at MyTest+<TestBug>d__2.MoveNext () [0x0003a] in /Users/mantas.kandrotas/Downloads/TimeoutUnityTest/Assets/Tests/MyTest.cs:21
at UnityEngine.TestTools.TestEnumerator+<Execute>d__7.MoveNext () [0x0003a] in /Users/mantas.kandrotas/Downloads/TimeoutUnityTest/Library/PackageCache/com.unity.test-framework@1.1.31/UnityEngine.TestRunner/NUnitExtensions/Attributes/TestEnumerator.cs:46
Prioritise and Follow this issue
Have a workaround or additional info about this issue?