We've refactored the test suite to make use of a hybrid wait-based approach for the Studio test suite. That is, when we expect elements of the GUI to change we use ComposeTestRule's waitUntil, blocking until a given condition is satisfied or a timeout is reached. This polls the UI for changes and also recomposes inbetween polls.
We have not entirely refactored out our static delays as some of the events we wait for are outside the scope of elements that fall entirely within Studio's GUI.
What are the changes implemented in this PR?
We make use of ComposeTestRules waitUntil, providing some new functions:
waitUntilNodeWithTextIsClickable
waitUntilNodeWithTextExists
waitUntilAssertionPasses
waitUntilTrue
Where appropriate, we now use one of the above wait 'family' of functions rather than more rudimentary functions like delayAndRecompose. However, not all of these have been removed.
While this PR has been open, we've migrated from grabl to Factory for our CI! We've included some of those changes here.
What is the goal of this PR?
We've refactored the test suite to make use of a hybrid wait-based approach for the Studio test suite. That is, when we expect elements of the GUI to change we use
ComposeTestRule
'swaitUntil
, blocking until a given condition is satisfied or a timeout is reached. This polls the UI for changes and also recomposes inbetween polls.We have not entirely refactored out our static delays as some of the events we wait for are outside the scope of elements that fall entirely within Studio's GUI.
What are the changes implemented in this PR?
We make use of
ComposeTestRule
swaitUntil
, providing some new functions:waitUntilNodeWithTextIsClickable
waitUntilNodeWithTextExists
waitUntilAssertionPasses
waitUntilTrue
Where appropriate, we now use one of the above wait 'family' of functions rather than more rudimentary functions like
delayAndRecompose
. However, not all of these have been removed.While this PR has been open, we've migrated from grabl to Factory for our CI! We've included some of those changes here.