Fix line coverage scope and test option 62/278662/4
authorSuyeon Hwang <stom.hwang@samsung.com>
Mon, 25 Jul 2022 02:08:32 +0000 (11:08 +0900)
committerSuyeon Hwang <stom.hwang@samsung.com>
Mon, 25 Jul 2022 05:33:32 +0000 (14:33 +0900)
This patch reduces the scope for checking line coverage. The line
coverage is for checking client API, so other files in this repo is not
target of the line coverage test.

Change-Id: If76a08f5e5402c1db8a455d4593472c588c1eb07
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
packaging/voice-control-elm.spec

index 8dfc7ba..3c6ed21 100644 (file)
@@ -28,6 +28,11 @@ BuildRequires:       pkgconfig(vconf)
 BuildRequires: gettext-tools
 BuildRequires: pkgconfig(gmock)
 
+%if 0%{?gcov:1}
+BuildRequires:  lcov
+BuildRequires:  zip
+%endif
+
 Requires(post):   /sbin/ldconfig
 Requires(postun): /sbin/ldconfig
 
@@ -117,6 +122,8 @@ rm -rf %{buildroot}
 builddir=$(basename $PWD)
 gcno_obj_dir=%{buildroot}%{_datadir}/gcov/obj/%{name}/"$builddir"
 mkdir -p "$gcno_obj_dir"
+find ./tests/ -name '*.gcno' -exec rm {} \;
+find . -name 'vc_elm_*.gcno' -exec rm {} \;
 find . -name '*.gcno' -exec cp --parents '{}' "$gcno_obj_dir" ';'
 %endif
 
@@ -131,7 +138,7 @@ setup() {
 
 test_main() {
     echo "test_main start"
-    launch_app org.tizen.vc-elm-unittests
+    launch_app org.tizen.vc-elm-unittests __AUL_SDK__ UNIT_TEST __LAUNCH_APP_MODE__ SYNC
 }
 
 teardown() {