executorch icon indicating copy to clipboard operation
executorch copied to clipboard

Improve cmake testing setup

Open kirklandsign opened this issue 9 months ago • 5 comments

  • Add build/Test.cmake and provide helper function for users to add tests targets Example:
et_cxx_test(my_test SOURCES my_test.cpp EXTRA_LIBS portable_kernels)

User need to invoke et_cxx_test and add their srcs/deps. Note: gtest, gmock, executorch are added to deps by default.

  • Update existign CMakeLists.txt and template test/utils/OSSTest.cmake.in for that
  • In test/run_oss_cpp_tests.sh, probe tests so user don't need to add them manually We will utilize add_test from cmake later

Test Plan: sh test/run_oss_cpp_tests.sh

kirklandsign avatar May 18 '24 00:05 kirklandsign

:link: Helpful Links

:test_tube: See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/3666

Note: Links to docs will display an error until the docs builds have been completed.

:white_check_mark: You can merge normally! (1 Unrelated Failure)

As of commit 229a90fb3221f5209fd10ef95038a9dd213d6872 with merge base dc36ef73eda0ec50cb9644191b03b70ad688a55e (image):

FLAKY - The following job failed but was likely due to flakiness present on trunk:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

pytorch-bot[bot] avatar May 18 '24 00:05 pytorch-bot[bot]

@kirklandsign has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot avatar May 18 '24 00:05 facebook-github-bot

I will update examples afterwards

kirklandsign avatar May 18 '24 00:05 kirklandsign

@kirklandsign has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot avatar May 18 '24 07:05 facebook-github-bot

@kirklandsign has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot avatar May 18 '24 07:05 facebook-github-bot

@kirklandsign has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot avatar May 20 '24 17:05 facebook-github-bot

@kirklandsign merged this pull request in pytorch/executorch@788676f3099c78983bf9fcaa19526081d2c2db10.

facebook-github-bot avatar May 20 '24 18:05 facebook-github-bot