Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Add more info for --type in run_tests.py and add android into all type#30458

Merged
fluttergithubbot merged 2 commits intoflutter:mainfrom
eggfly:run_tests_type_help
Dec 28, 2021
Merged

Add more info for --type in run_tests.py and add android into all type#30458
fluttergithubbot merged 2 commits intoflutter:mainfrom
eggfly:run_tests_type_help

Conversation

@eggfly
Copy link
Member

@eggfly eggfly commented Dec 22, 2021

It's a small improvement for --type help, for who want to use run_tests.py.

Pre-launch Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • I read the [Tree Hygiene] wiki page, which explains my responsibilities.
  • I read and followed the [Flutter Style Guide] and the [C++, Objective-C, Java style guides].
  • I listed at least one issue that this PR fixes in the description above.
  • I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test-exempt. See [testing the engine] for instructions on
    writing and running engine tests.
  • I updated/added relevant documentation (doc comments with ///).
  • I signed the [CLA].
  • All existing and new tests are passing.

@eggfly eggfly changed the title Add more help info for --type in run_tests.py Add more help info for --type in run_tests.py Dec 22, 2021
Copy link
Contributor

@chinmaygarde chinmaygarde left a comment

Choose a reason for hiding this comment

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

The doc changes lgtm. But this changes the default behavior of the script. Not sure if this is the cause of the CI failure. But I agree, this all should include android.

@eggfly eggfly requested a review from zanderso December 23, 2021 02:44
@eggfly
Copy link
Member Author

eggfly commented Dec 23, 2021

The doc changes lgtm. But this changes the default behavior of the script. Not sure if this is the cause of the CI failure. But I agree, this all should include android.

Yes it changes the behavior, and I think it should include android into all, so I add it.

The CI failure is in shell_unittests, seems like it's not related to android tests(android test is an apk installed into a device). Let me try the CI checking again.

@eggfly eggfly requested a review from chinmaygarde December 23, 2021 03:06
@eggfly eggfly added the waiting for tree to go green This PR is approved and tested, but waiting for the tree to be green to land. label Dec 23, 2021
@eggfly
Copy link
Member Author

eggfly commented Dec 23, 2021

@chinmaygarde The last failed CI log:

Maybe the shell_unittest is flaky or failed and then fixed.

Now the CI test passed!

grep -nr run_tests.py . found:

./shell/platform/android/test/README.md:22:5. Build and run with `testing/run_tests.py [--type=java] [--java-filter=<test_class_name>]`.
./ci/builders/windows_host_engine.json:33:                    "script": "flutter/testing/run_tests.py",
./testing/dart/observatory/README.md:4:The `run_tests.py` script disables the observatory for other tests in the
./testing/ios/IosUnitTests/README.md:11:flutter/testing/run_tests.py --type=objc
./testing/ios/IosUnitTests/README.md:18:into Xcode after running `run_tests.py`, only a few basic tests will appear
./testing/ios/IosUnitTests/README.md:25:[`run_tests.py`](../../run_tests.py) again.
./testing/run_tests.sh:8:python "${CURRENT_DIR}/run_tests.py" --variant="${BUILD_VARIANT}" --type=engine,dart,benchmarks
./testing/analyze_core_dump.sh:5:# This script can be invoked by the run_tests.py script after an
./lib/spirv/README.md:39:To test the exception tests directly: `./testing/run_tests.py --type dart --dart-filter spirv_exception_test.dart`
./lib/spirv/README.md:49:To test the pixel tests directly: `./testing/run_tests.py --type dart --dart-filter fragment_shader_test.dart`

grep -nr run_tests . | grep all and found nothing.

These scripts seems like they are rarely using the all type. So I think it's OK.

The last failed CI log:

[ RUN      ] ShellTest.DiscardLayerTreeOnResize
../../flutter/shell/common/shell_unittests.cc:2373: Failure
Expected equality of these values:
  1
  external_view_embedder->GetSubmittedFrameCount()
    Which is: 2
[FATAL:flutter/fml/memory/weak_ptr.h(253)] Check failed: (checker_.checker).IsCreationThreadCurrent(). 
[ERROR:flutter/fml/backtrace.cc(116)] Caught signal SIGABRT during program execution.
Frame 0: 0x7fc33867442a abort
Frame 1: 0x26bcec9 Unknown
Frame 2: 0x26bcea8 fml::LogMessage::~LogMessage()
Frame 3: 0x260ee4c fml::WeakPtrFactory<>::CheckThreadSafety()
Frame 4: 0x2602cc9 fml::WeakPtrFactory<>::~WeakPtrFactory()
Frame 5: 0x25ad594 flutter::Shell::~Shell()
Frame 6: 0x22db9ab std::__1::default_delete<>::operator()()
Frame 7: 0x22db92c std::__1::unique_ptr<>::reset()
Frame 8: 0x22d8889 std::__1::unique_ptr<>::~unique_ptr()
Frame 9: 0x24082cd flutter::testing::ShellTest_DiscardLayerTreeOnResize_Test::TestBody()
Frame 10: 0x42b97bb testing::internal::HandleSehExceptionsInMethodIfSupported<>()
Frame 11: 0x42a9d67 testing::internal::HandleExceptionsInMethodIfSupported<>()
Frame 12: 0x42993c3 testing::Test::Run()
Frame 13: 0x4299a84 testing::TestInfo::Run()
Frame 14: 0x429a08d testing::TestSuite::Run()
Frame 15: 0x42a3851 testing::internal::UnitTestImpl::RunAllTests()
Frame 16: 0x42bcbfb testing::internal::HandleSehExceptionsInMethodIfSupported<>()
Frame 17: 0x42ab7a7 testing::internal::HandleExceptionsInMethodIfSupported<>()
Frame 18: 0x42a344f testing::UnitTest::Run()
Frame 19: 0x40d6931 RUN_ALL_TESTS()
Frame 20: 0x40d67b2 main
Frame 21: 0x7fc3386602e1 __libc_start_main
Frame 22: 0x22c532a _start
<<<<<<<<<<<<<<<<<<<<<
Command run successfully in 8.25 seconds: /tmp/clean_engine/src/out/host_debug_unopt/exe.unstripped/fml_unittests --gtest_filter=-*TimeSensitiveTest* --gtest_repeat=2 --gtest_shuffle
Running runtime_unittests in /tmp/clean_engine/src

@fluttergithubbot fluttergithubbot removed the waiting for tree to go green This PR is approved and tested, but waiting for the tree to be green to land. label Dec 23, 2021
@flutter flutter deleted a comment from fluttergithubbot Dec 23, 2021
@eggfly eggfly requested a review from dnfield December 24, 2021 02:43
@eggfly eggfly changed the title Add more help info for --type in run_tests.py Add more info for --type in run_tests.py and add android into all type Dec 24, 2021
Copy link
Member

@zanderso zanderso left a comment

Choose a reason for hiding this comment

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

lgtm

@zanderso zanderso added the waiting for tree to go green This PR is approved and tested, but waiting for the tree to be green to land. label Dec 28, 2021
@fluttergithubbot fluttergithubbot merged commit 2d7938e into flutter:main Dec 28, 2021
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Dec 30, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

waiting for tree to go green This PR is approved and tested, but waiting for the tree to be green to land.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants