Conversation
…tion in activity worker
The following tests timeout after 1 minute that occurs in the
waitActivityWorkerThreadUntilIdle() function. This is caused by the
unhandled exception in the activity worker thread, because a new test
attempts to re-open the already-closed connection to the database (done
in the tearDown method of the base class):
Exception in thread "SchedulerActivityViewModelThread" java.lang.IllegalStateException: attempt to re-open an already-closed object: SQLiteDatabase: :memory:
After manual execution, there are some tests that missed the call to
waitActivityWorkerThreadUntilIdle() needed to drain the activity worker
thread before executing a new test (the rational behind this described in ef5757a).
So, to avoid the same issue in the future, and also repeating ourselves
multiple times, we'll always drain the activity worker thread after test
finished.
---
> Task :testDebugUnitTest
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should successfully create schedule with PIN when authentication not required FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1305
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should rearrange schedules in the list when sorting criteria changed FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1425
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should successfully create schedule without PIN when authentication is required FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1327
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should reflect updated time in the selected schedule view FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1451
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should update time in the selected schedule FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1380
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should start authentication prompt activity when authentication is required FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1347
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimePickerDialog.test should successfully create schedule with picked time FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1274
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should refresh SIM name ONLY when the corresponding subscription changed FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:364
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should regenerate time-sensitive data in SIM entries FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:444
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should refresh next upcoming schedule summary on subscriptions changed FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:387
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should regenerate locale-sensitive data FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:413
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should refresh SIM name when the corresponding subscription changed FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:332
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…tion in activity worker
The following tests timeout after 1 minute that occurs in the waitActivityWorkerThreadUntilIdle() function. This is caused by the unhandled exception in the activity worker thread, because a new test attempts to re-open the already-closed connection to the database (done in the tearDown method of the base class):
After manual execution, there are some tests that missed the call to waitActivityWorkerThreadUntilIdle() needed to drain the activity worker thread before executing a new test (the rational behind this described in ef5757a). So, to avoid the same issue in the future, and also repeating ourselves multiple times, we'll always drain the activity worker thread after test finished.
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should successfully create schedule with PIN when authentication not required FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1305
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should rearrange schedules in the list when sorting criteria changed FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1425
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should successfully create schedule without PIN when authentication is required FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1327
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should reflect updated time in the selected schedule view FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1451
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should update time in the selected schedule FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1380
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimeMutations.test should start authentication prompt activity when authentication is required FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1347
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$TimePickerDialog.test should successfully create schedule with picked time FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:1274
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should refresh SIM name ONLY when the corresponding subscription changed FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:364
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should regenerate time-sensitive data in SIM entries FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:444
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should refresh next upcoming schedule summary on subscriptions changed FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:387
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should regenerate locale-sensitive data FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:413
SchedulerActivityTest > com.github.iusmac.sevensim.ui.scheduler.SchedulerActivityTest$Toolbar.test should refresh SIM name when the corresponding subscription changed FAILED
java.util.concurrent.TimeoutException at SchedulerActivityTest.kt:332