-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Patrol 2.0 shortcomings #1341
Comments
Q: Test bundling is optional or it will be the only option in 2.0? |
A: It'll be the only way of running tests in 2.0. |
You can run set-ups manually at the top of the callback you pass to Using tear-downs is not recommended since there's no guarantee they'll execute, due to e.g. fatal native crash. I'm curios to hear what you think about this. I'd also like to bring back support for set-ups and tear-downs but it was decided not needed for 2.0. |
Please also note that |
@bartekpacia In my case I don't have this MainActivityTest.java should I add this file and code according to patrol_cli_2.0.0 documentation as getting some errors in test_bundle.dart and build.gradle on activating patrol_cli to 2.0.0 Is there any way to go back on patrol_cli_1.1.11? |
Sure, you can easily downgrade to v1:
|
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
Removed info about `tearDown()` and `setUp()` callbacks when using native automation. These callbacks must not be used in Patrol 2.0. See #1341 for more details.
Removed info about `tearDown()` and `setUp()` callbacks when using native automation. These callbacks must not be used in Patrol 2.0. See #1341 for more details.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
There are separate issues for this topics, closing |
This issue has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar problem, please file a new issue. Make sure to follow the template and provide all the information necessary to reproduce the issue. |
In this issue, we gather a list of problems, bugs, and lacks related to the test bundling feature. This is mostly an extract of problems mentioned in this comment.
Individual issues might be created later.
preserve the tree structure of Dart tests when translated to native tests (update: see #1502)
Given the following hierarchy of the
integration_test
directory:the results are presented like this on a native platform (in the example below: Android:)
but should be presented like this instead:
In other words, the hierarchy is removed, but it's emulated by
.
(a dot).group()
cannot be used (update: see #1619)This stems from how tests are registered for execution by
patrolTest()
.See also:
set-up and tear-down callbacks cannot be used (update: see #1503)
Or rather: they can be used, but they execute in a very different order.
This applies to
setUp()
,setUpAll()
,tearDown()
,tearDownAll()
, and similar.Assume there are 3 tests in the
integration_test
director:Source code
Here's how it'll end up being:
Logs
This is because of the way we implemented running a particular test. Tests that appear before it aren't actually skipped – they are run but finish immediately. Think: fallthrough.
The
main()
function must not be asynchronous.Example of incorrect test:
Example of correct test:
The text was updated successfully, but these errors were encountered: