Skip to content

Conversation

@nturgut
Copy link
Contributor

@nturgut nturgut commented Oct 9, 2020

Description

There are no tests in the flutter/flutter repo right now that tests the integration_test packages usage with flutter drive on web. Current driver tests does not cover integration_test package. This created a P0 yesterday. I'm carrying the text_editing test we have on the engine to flutter repo.

The original test used: https://github.com/flutter/engine/blob/master/e2etests/web/regular_integration_tests/test_driver/text_editing_integration.dart

Why this test:

  • already migrated to integration_test (from e2e) so no migration needed.
  • provides a very good coverage for other features:
  1. tests platform channels
  2. tests text editing
  3. tests keyboard keys

Related Issues

#67560

Tests

This is a test file, however it will only be tested after the following steps.

-> add a new validation to the recipes (recipe side change: https://flutter-review.googlesource.com/c/recipes/+/7060)
-> add this as a new builder to flutter/infra
-> add this change to try builds under flutter/flutter

Checklist

Before you create this PR, confirm that it meets all requirements listed below by checking the relevant checkboxes ([x]). This will ensure a smooth and quick review process.

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I signed the CLA.
  • I read and followed the Flutter Style Guide, including Features we expect every widget to implement.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I updated/added relevant documentation (doc comments with ///).
  • All existing and new tests are passing.
  • The analyzer (flutter analyze --flutter-repo) does not report any problems on my PR.
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

Did any tests fail when you ran them? Please read Handling breaking changes.

@nturgut nturgut requested review from ditman and mdebbar October 9, 2020 00:00
@flutter-dashboard flutter-dashboard bot added the c: contributor-productivity Team-specific productivity, code health, technical debt. label Oct 9, 2020
@google-cla google-cla bot added the cla: yes label Oct 9, 2020
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you include the command for running chromedriver on port 4444?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done. I also added links for more information.

Copy link
Member

@ditman ditman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, with a couple of comments!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be integration_test: ^0.9.2? e2e is discontinued.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm changing the these pubspec due to update-packages. I think they didn't migrated those tests yet. I'm not sure which team is using them though :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, this test is involved, and text edition is still changing quite a bit, do you think this can break because of legit changes in the way text editing is handled in the engine? Can this prevent engine rolls to flow into flutter?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! yes this is a very good test.

I think the current situation is worse (which happened a few times)

  • If there is a change on the framework, engine tests won't run and won't break.
  • developer will merge the change to flutter/flutter
  • engine developers will start seeing failure on random PRs for felt firefox step (since it's the first step that runs integration tests)
  • Later (after a research probably) the flutter/flutter PR will be reverted
  • PR author will try to test the PR running felt locally, this is also a little tricky since there are many flutter/flutter developers who does not normally do engine development

In the new process,

  • flutter/flutter developers would be protected against the changes to e2e and also against platform channels and text editing changes
  • flutter/engine developers, will break the the tests on the engine side first if they are making a change that would change the communication between flutter and the web engine (so the tree will be read)
  • If the change is on purpose, then there should be a handshake (there should be 3 PRs in a row, first one would change the test or the code to a temporary state. Last one will fix it.)

I think this is good since this is also reminds both engine/flutter PRs about the other repo. If this was a package (rather than the engine itself) best could have been to use a version in the pubspec of course. But I think we have this problem for many issues between engine<->flutter repo.

Thanks for the reminder though I'm chat with @Hixie to see what can we do for this type of changes. May be we can add a guide for developers.

@nturgut
Copy link
Contributor Author

nturgut commented Oct 9, 2020

When I check the results Google tests are passing. It didn't synced the status somehow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

c: contributor-productivity Team-specific productivity, code health, technical debt.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants