Adjust test option merging logic for tests in TEST_MAPPING file.

include-annotation applies to all tests, which is use to only include tests
with certain (Presubmit) annotations. That can cause tests don't rely on
the annotation to be skipped after the merge.
exclude-annotation can be used to skip flaky tests. Some test packages don't
use the annotation so there is no need to use the exclude-annotation option.
By keeping any exclude-annotation option, we try the best to not introduce
flaky tests unexpectedly.

This is a temp fix until a suite run redesign to support suite to run tests
with different options to run in its own test run.

Bug: 117880789
Test: unittest
Change-Id: I55bedf0ea443777505b4e5b73d061152e1f7a0c9
2 files changed
tree: b13d1e84ea10966125498198866398594b53bc97
  1. atest/
  2. prod-tests/
  3. proto/
  4. python-lib/
  5. remote/
  6. res/
  7. src/
  8. tests/
  9. util-apps/
  10. .classpath
  11. .gitignore
  12. .project
  13. Android.bp
  14. Android.mk
  15. atest_tradefed.sh
  16. CleanSpec.mk
  17. error_prone_rules.mk
  18. MANIFEST.mf
  19. OWNERS
  20. PREUPLOAD.cfg
  21. pylintrc
  22. README.md
  23. run_tf_cmd.sh
  24. script_help.sh
  25. TEST_MAPPING
  26. tradefed.sh
  27. tradefed_win.bat
  28. verify.sh
README.md

Trade Federation (TF / tradefed)

TF is a test harness used to drive Android automated testing. It runs on test hosts and monitors the connected devices, handling test scheduling & execution and device management.

Other test harnesses like Compatibility Test Suite (CTS) and Vendor Test Suite (VTS) use TF as a basis and extend it for their particular needs.

Building TF:

  • source build/envsetup.sh
  • tapas tradefed-all
  • make -j8

More information at: https://source.android.com/devices/tech/test_infra/tradefed/