From: David Steele Date: Thu, 17 Aug 2023 10:33:22 +0000 (+0100) Subject: Updated test harness README.md X-Git-Tag: dali_2.2.41~6^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F67%2F297367%2F1;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git Updated test harness README.md Cleaned up the readme, Removed out of date info Added new command line options Change-Id: I9dfa4ed3413809335052db8ca99303cd61263936 Signed-off-by: David Steele --- diff --git a/automated-tests/README.md b/automated-tests/README.md index 59a7ca7..9f1986c 100644 --- a/automated-tests/README.md +++ b/automated-tests/README.md @@ -1,7 +1,7 @@ Testing environment {#auto_testing} =================== -The new test environment from Tizen is the Web-TCT test suite. This was written for testing web components, but can easily be used for testing Dali. +The current test environment from Tizen is the Web-TCT test suite. This was written for testing web components, but can easily be used for testing Dali. The tests remain compatible with the previous TET test suite. Each of the DALi repositories, **dali-core**, **dali-adaptor** and **dali-toolkit**, have their own test suites under the `automated-tests` folder. Within the src folder are a number of secondary folders - these correspond to 'API' tests and internal (for desktop testing only) @@ -61,7 +61,7 @@ Run the following commands: cd automated-tests ./build.sh -This will build dali-adaptor, dali-adaptor-internal and dali-platform-abstraction test sets. +This will build dali-adaptor, dali-adaptor-internal, dali-graphics and dali-platform-abstraction test sets. Test sets can be built individually: @@ -87,11 +87,20 @@ To execute tests, cd into automated-tests and run ./execute.sh -This will execute dali and dali-internal test sets. Note that the output summary for the first will be printed before running the second. +To execute a subset of tests, you can run individual test sets, e.g. + + ./execute.sh dali-adaptor + +To execute a specific test, just pass it on the command line: + + ./execute.sh UtcDaliApplicationNew01 + +To execute a matching subset of tests, use the prefix option: + + ./execute.sh -p UtcDaliApplication -By default the tests execute in parallel, which is faster but does not produce any test case output files. Use this to execute the tests in series and log test output to stdout/err +will execute all tests that start with the prefix "UtcDaliApplication". - ./execute.sh -S To use test kit lite, (which is very slow), @@ -101,9 +110,6 @@ To see the test kit lite results, copy the style folder from web-tct_2.2.1_r1/to firefox --new-window summary.xml -To execute a subset of tests, you can run individual test sets, e.g. - - ./execute.sh dali-adaptor To get full coverage output (you need to first build dali libraries with --coverage), run @@ -145,9 +151,11 @@ For Dali Adaptor, cd into automated-tests, and use: sudo ./tcbuild build dali-adaptor sudo ./tcbuild build dali-adaptor-internal + sudo ./tcbuild build dali-graphics sudo ./tcbuild build dali-platform-abstraction ./tcbuild install dali-adaptor ./tcbuild install dali-adaptor-internal + ./tcbuild install dali-graphics ./tcbuild install dali-platform-abstraction Ensure your handset's filesystem is writable: @@ -167,11 +175,6 @@ You can find the output files under /opt/tct/manager/result/ Adding tests ============ -To Managed API --------------- - -If you are adding test cases for new or existing managed API (CAPI), you need to add your changes to the src/dali mirror, and copy your change to the managed test suite in core-api. You need to inform HQ of your update. - For internal API ---------------- @@ -191,7 +194,7 @@ If you are adding test cases to existing files, then all you need to do is creat Note that **the parentheses in the method signature must not be empty** (i.e., it must violate our coding convention and follow __exactly__ this pattern: `int UtcDaliMyTestcaseName(void)`), as it's parsed by an awk script to auto-generate the testcase arrays in the main header file. Neither may any comments on the same line contain empty parentheses. -You can contine to use the TET api, e.g. `tet_infoline`, `tet_result` and our test check methods `DALI_TEST_CHECK`, `DALI_TEST_EQUALS`, etc. +You can use the previous TET api, e.g. `tet_infoline`, `tet_result` and our test check methods `DALI_TEST_CHECK`, `DALI_TEST_EQUALS`, etc. If you need any non-test methods or variables, ensure they are wrapped in an anonymous namespace. @@ -239,14 +242,14 @@ Debugging On desktop, you can debug the tests by running gdb on the test program: $ cd automated-tests - $ gdb build/src/dali-adaptor/tct-dali-adaptor-core + $ ./execute.sh -d gdb> r replace `` with the name of the failing testcase. For example, using testcase UtcDaliLoadCompletion from the dali-platform-abstraction test suite: - $ gdb build/src/dali-platform-abstraction/tct-dali-platform-abstraction-core + $ ./execute.sh -d UtcDaliLoadCompletion gdb> r UtcDaliLoadCompletion