--- /dev/null
+/*
+ * Copyright (c) 2013 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+/**
+ * @file TestCases.cpp
+ * @author Karol Pawlowski (k.pawlowski@samsung.com)
+ * @author Tomasz Iwanek (t.iwanek@samsung.com)
+ * @version 1.0
+ * @brief Background page installation test's bodies
+ */
+
+#include <string>
+#include <dpl/test/test_runner.h>
+#include <InstallerWrapper.h>
+
+using namespace InstallerWrapper;
+
+////////////////////////////////////////////////////////////////////////////////
+
+RUNNER_TEST_GROUP_INIT(BackgroundPage)
+
+/*
+Name: widgetWithBackgroundPage
+Description: Tests if widget with background page is installed correctly
+Expected: widget should be installed correctly
+*/
+RUNNER_TEST(widgetWithBackgroundPage)
+{
+ std::string tizenId;
+ RUNNER_ASSERT(install(miscWidgetsStuff + "widgets/bg-00-with_bg.wgt",
+ tizenId) == InstallerWrapper::Success);
+ uninstall(tizenId);
+}
+
+/*
+Name: missingBackgroundFile
+Description: Tests if widget with declared in conifg background page
+ but missing background file will be installed correctly.
+Expected: widget should NOT be installed
+*/
+RUNNER_TEST(missingBackgroundFile)
+{
+ std::string tizenId;
+ if(install(miscWidgetsStuff + "widgets/bg-01-missing_file.wgt",
+ tizenId) == InstallerWrapper::Success) {
+ uninstall(tizenId);
+ RUNNER_ASSERT_MSG(false, "Invalid widget package installed");
+ }
+}
+
+/*
+Name: widgetWithoutBackgroundPage
+Description: Complementary test to check if normal widget\
+ without background page is successfully installed
+Expected: widget should be installed
+*/
+RUNNER_TEST(widgetWithoutBackgroundPage)
+{
+ std::string tizenId;
+ RUNNER_ASSERT(install(miscWidgetsStuff + "widgets/bg-02-without_bg.wgt",
+ tizenId) == InstallerWrapper::Success);
+ uninstall(tizenId);
+}
# @author Karol Pawlowski (k.pawlowski@samsung.com)
#
-
-# TODO cleanup dependencies
PKG_CHECK_MODULES(COMMON_LIB_PKGS
dbus-1
libpcrecpp
REQUIRED
)
-INCLUDE(CMakeUtils.txt)
-
pkg_search_module(dpl REQUIRED dpl-efl)
pkg_search_module(dpl-test REQUIRED dpl-test-efl)
include_directories(
${dpl_INCLUDE_DIRS}
${dpl-test_INCLUDE_DIRS}
- ${CMAKE_CURRENT_SOURCE_DIR}/common
)
-ADD_SUBDIRECTORY(common)
+SET(COMMON_INCLUDES "${CMAKE_CURRENT_SOURCE_DIR}")
+
+SET_PROPERTY(GLOBAL APPEND PROPERTY COMMON_TESTS_LIBRARY ${WRT_TEST_LIBRARY})
+
+SET_PROPERTY(GLOBAL APPEND PROPERTY TESTS_INCLUDE_DIRS ${COMMON_LIB_PKGS_INCLUDE_DIRS})
+
+SET_PROPERTY(GLOBAL APPEND PROPERTY TESTS_LIBRARY_DIRS ${COMMON_LIB_PKGS_LIBRARY_DIRS})
+
+SET_PROPERTY(GLOBAL APPEND PROPERTY TESTS_LIBRARIES ${COMMON_LIB_PKGS_LIBRARIES})
+
+SET(WRT_DETAIL_SOURCES
+ ${CMAKE_CURRENT_SOURCE_DIR}/InstallerWrapper.cpp
+ ${CMAKE_CURRENT_SOURCE_DIR}/ManifestFile.cpp
+)
+
+INCLUDE_DIRECTORIES(${COMMON_INCLUDES})
+INCLUDE_DIRECTORIES(${COMMON_LIB_PKGS_INCLUDE_DIRS})
+
+ADD_LIBRARY(${WRT_TEST_LIBRARY} STATIC ${WRT_DETAIL_SOURCES})
SET(INSTALLER_TESTS_SOURCES
${CMAKE_CURRENT_SOURCE_DIR}/TestInit.cpp
- ${CMAKE_CURRENT_SOURCE_DIR}/TestCases.cpp
+ ${CMAKE_CURRENT_SOURCE_DIR}/ManifestTests.cpp
+ ${CMAKE_CURRENT_SOURCE_DIR}/BackgroundPageTests.cpp
+ ${CMAKE_CURRENT_SOURCE_DIR}/NonRootUserTests.cpp
+ ${CMAKE_CURRENT_SOURCE_DIR}/NPluginsInstallTests.cpp
+ ${CMAKE_CURRENT_SOURCE_DIR}/ParsingTizenAppserviceTests.cpp
)
SET(INSTALLER_TESTS_TARGET "wrt-installer-tests-general")
+# Functions used to build test targets (proper sources, includes, libs are
+# added automatically)
+FUNCTION(WRT_TEST_BUILD TARGET_NAME)
+ SET(SOURCES "${ARGN}")
+ ADD_EXECUTABLE("${TARGET_NAME}" ${SOURCES})
+
+ # get include dirs global property
+ GET_PROPERTY(INCLUDE_DIRS GLOBAL PROPERTY TESTS_INCLUDE_DIRS)
+ GET_PROPERTY(TEST_INCLUDE_DIRS GLOBAL PROPERTY ${TARGET_NAME}_INCLUDE_DIRS)
+ INCLUDE_DIRECTORIES(
+ ${INCLUDE_DIRS}
+ ${TEST_INCLUDE_DIRS}
+ )
+
+ # get library dirs global property
+ GET_PROPERTY(LIBRARY_DIRS GLOBAL PROPERTY TESTS_LIBRARY_DIRS)
+ GET_PROPERTY(TEST_LIBRARY_DIRS GLOBAL PROPERTY ${TARGET_NAME}_LIBRARY_DIRS)
+ LINK_DIRECTORIES(
+ ${LIBRARY_DIRS}
+ ${TEST_LIBRARY_DIRS}
+ )
+
+ # get link libraries global property
+ GET_PROPERTY(LINK_LIBRARIES GLOBAL PROPERTY TESTS_LIBRARIES)
+ GET_PROPERTY(TEST_LIBRARIES GLOBAL PROPERTY ${TARGET_NAME}_LIBRARIES)
+ TARGET_LINK_LIBRARIES("${TARGET_NAME}"
+ ${LINK_LIBRARIES}
+ ${TEST_LIBRARIES}
+ )
+ENDFUNCTION(WRT_TEST_BUILD)
+
+FUNCTION(WRT_TEST_INSTALL)
+ SET_TARGET_PROPERTIES(${ARGV} PROPERTIES
+ BUILD_WITH_INSTALL_RPATH ON
+ INSTALL_RPATH_USE_LINK_PATH ON
+ )
+ INSTALL(TARGETS ${ARGV}
+ DESTINATION bin
+ PERMISSIONS OWNER_READ
+ OWNER_WRITE
+ OWNER_EXECUTE
+ GROUP_READ
+ GROUP_EXECUTE
+ WORLD_READ
+ WORLD_EXECUTE
+ )
+ENDFUNCTION(WRT_TEST_INSTALL)
+
WRT_TEST_BUILD(${INSTALLER_TESTS_TARGET} ${INSTALLER_TESTS_SOURCES})
WRT_TEST_INSTALL(${INSTALLER_TESTS_TARGET})
target_link_libraries(${INSTALLER_TESTS_TARGET}
INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/widgets/inst_nplug_2.wgt DESTINATION /opt/share/widget/tests/installer/widgets/)
INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/widgets/inst_nplug_3.wgt DESTINATION /opt/share/widget/tests/installer/widgets/)
INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/widgets/inst_nplug_4.wgt DESTINATION /opt/share/widget/tests/installer/widgets/)
-INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/widgets/appservice_dispos.wgt DESTINATION /opt/share/widget/tests/installer/widgets/)
\ No newline at end of file
+INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/widgets/appservice_dispos.wgt DESTINATION /opt/share/widget/tests/installer/widgets/)
+++ /dev/null
-# @file CMakeUtils.txt
-# @author Zbigniew Kostrzewa (z.kostrzewa@samsung.com)
-# @author Pawel Sikorski (p.sikorski@samsung.com)
-# @author Krzysztof Jackiewicz (k.jackiewicz@samsung.com)
-# @version 1.0
-# @brief
-#
-
-#
-# Discovers target's INCLUDE_DIRECTORIES and LINK_DIRECTORIES.
-# This is done by retrieving the directory target was built in and
-# fetching appropriate properties of that directory.
-FUNCTION(WRT_INTROSPECT_TARGET PREFIX TARGET_NAME)
- GET_TARGET_PROPERTY(LOCATION ${TARGET_NAME} LOCATION)
- IF(${LOCATION} STREQUAL "LOCATION-NOTFOUND")
- MESSAGE(FATAL_ERROR "Target '${TARGET_NAME}' introspection failed")
- ELSE(${LOCATION} STREQUAL "LOCATION-NOTFOUND")
- STRING(FIND ${LOCATION} "/" LAST_SLASH_POSITION REVERSE)
- STRING(SUBSTRING ${LOCATION} 0 ${LAST_SLASH_POSITION} LOCATION)
-
- GET_DIRECTORY_PROPERTY(INCLUDE_DIRS DIRECTORY ${LOCATION} INCLUDE_DIRECTORIES)
- SET("${PREFIX}_INCLUDE_DIRS" ${INCLUDE_DIRS} PARENT_SCOPE)
-
- GET_DIRECTORY_PROPERTY(LIBRARY_DIRS DIRECTORY ${LOCATION} LINK_DIRECTORIES)
- SET("${PREFIX}_LIBRARY_DIRS" ${LIBRARY_DIRS} PARENT_SCOPE)
- ENDIF(${LOCATION} STREQUAL "LOCATION-NOTFOUND")
-ENDFUNCTION(WRT_INTROSPECT_TARGET)
-
-FUNCTION(WRT_TEST_LIBRARY)
- SET_PROPERTY(GLOBAL APPEND PROPERTY COMMON_TESTS_LIBRARY ${ARGV})
-ENDFUNCTION(WRT_TEST_LIBRARY)
-
-#
-# Replacement functions for standard (w/o "WRT_" prefix) CMake functions.
-# They store supplied arguments in global properties to assign them to tests.
-# Anything added with this functions is used by all targets that are built with
-# WRT_TEST_BUILD function.
-
-#
-# Appends directories to global property TESTS_INCLUDE_DIRS which is
-# then read by WRT_TEST_BUILD and its content is forwarded to
-# command INCLUDE_DIRECTORIES() (for all targets).
-FUNCTION(WRT_INCLUDE_DIRECTORIES)
- SET_PROPERTY(GLOBAL APPEND PROPERTY TESTS_INCLUDE_DIRS ${ARGV})
-ENDFUNCTION(WRT_INCLUDE_DIRECTORIES)
-
-#
-# Appends directories to global property TESTS_LIBRARY_DIRS which is
-# then read by WRT_TEST_BUILD and its content is forwarded to
-# command LINK_DIRECTORIES() (for all targets).
-FUNCTION(WRT_LINK_DIRECTORIES)
- SET_PROPERTY(GLOBAL APPEND PROPERTY TESTS_LIBRARY_DIRS ${ARGV})
-ENDFUNCTION(WRT_LINK_DIRECTORIES)
-
-#
-# Appends directories to global property TESTS_LIBRARIES which is
-# then read by WRT_TEST_BUILD and its content is forwarded to
-# command TARGET_LINK_LIBRARIES() (for all targets).
-FUNCTION(WRT_TARGET_LINK_LIBRARIES)
- SET_PROPERTY(GLOBAL APPEND PROPERTY TESTS_LIBRARIES ${ARGV})
-ENDFUNCTION(WRT_TARGET_LINK_LIBRARIES)
-
-#
-# Convenience method that fills TESTS_INCLUDE_DIRS, TESTS_LIBRARY_DIRS
-# and TESTS_LIBRARIES with values discovered from introspecting supplied
-# targets.
-# Function takes arbitrary number of targets.
-FUNCTION(WRT_ADD_INTERNAL_DEPENDENCIES)
- FOREACH(DEPENDENCY ${ARGV})
- WRT_INTROSPECT_TARGET(prefix ${DEPENDENCY})
- WRT_INCLUDE_DIRECTORIES(${prefix_INCLUDE_DIRS})
- WRT_LINK_DIRECTORIES(${prefix_LIBRARY_DIRS})
- WRT_TARGET_LINK_LIBRARIES(${DEPENDENCY})
- ENDFOREACH(DEPENDENCY)
-ENDFUNCTION(WRT_ADD_INTERNAL_DEPENDENCIES)
-
-
-#
-# Replacement functions for standard (w/o "WRT_" prefix) CMake functions.
-# They store supplied arguments in global properties to assign them to specific
-# tests. Properties names are based on the test target name.
-# Anything added with this functions is used only by the specified target that
-# is built with WRT_TEST_BUILD function.
-
-#
-# Appends directories to global property ${TARGET_NAME}_INCLUDE_DIRS
-# which is then read by WRT_TEST_BUILD and its content is forwarded to
-# command INCLUDE_DIRECTORIES() (for specified target).
-FUNCTION(WRT_TEST_INCLUDE_DIRECTORIES TARGET_NAME)
- SET_PROPERTY(GLOBAL APPEND PROPERTY ${TARGET_NAME}_INCLUDE_DIRS ${ARGN})
-ENDFUNCTION(WRT_TEST_INCLUDE_DIRECTORIES)
-
-#
-# Appends directories to global property ${TARGET_NAME}_LIBRARY_DIRS
-# which is then read by WRT_TEST_BUILD and its content is forwarded to
-# command LINK_DIRECTORIES() (for specified target).
-FUNCTION(WRT_TEST_LINK_DIRECTORIES TARGET_NAME)
- SET_PROPERTY(GLOBAL APPEND PROPERTY ${TARGET_NAME}_LIBRARY_DIRS ${ARGN})
-ENDFUNCTION(WRT_TEST_LINK_DIRECTORIES)
-
-#
-# Appends directories to global property ${TARGET_NAME}_LIBRARIES
-# which is then read by WRT_TEST_BUILD and its content is forwarded to
-# command TARGET_LINK_LIBRARIES() (for specified target).
-FUNCTION(WRT_TEST_TARGET_LINK_LIBRARIES TARGET_NAME)
- SET_PROPERTY(GLOBAL APPEND PROPERTY ${TARGET_NAME}_LIBRARIES ${ARGN})
-ENDFUNCTION(WRT_TEST_TARGET_LINK_LIBRARIES)
-
-#
-# Convenience method that fills ${TARGET_NAME}_INCLUDE_DIRS,
-# ${TARGET_NAME}_LIBRARY_DIRS and ${TARGET_NAME}_LIBRARIES with
-# values discovered from introspecting supplied targets.
-# Function takes arbitrary number of targets.
-FUNCTION(WRT_TEST_ADD_INTERNAL_DEPENDENCIES TARGET_NAME)
- FOREACH(DEPENDENCY ${ARGN})
- WRT_INTROSPECT_TARGET(prefix ${DEPENDENCY})
- WRT_TEST_INCLUDE_DIRECTORIES(${TARGET_NAME} ${prefix_INCLUDE_DIRS})
- WRT_TEST_LINK_DIRECTORIES(${TARGET_NAME} ${prefix_LIBRARY_DIRS})
- WRT_TEST_TARGET_LINK_LIBRARIES(${TARGET_NAME} ${DEPENDENCY})
- ENDFOREACH(DEPENDENCY)
-ENDFUNCTION(WRT_TEST_ADD_INTERNAL_DEPENDENCIES)
-
-# Functions used to build test targets (proper sources, includes, libs are
-# added automatically)
-FUNCTION(WRT_TEST_BUILD TARGET_NAME)
- SET(SOURCES "${ARGN}")
- ADD_EXECUTABLE("${TARGET_NAME}" ${SOURCES})
-
- # get include dirs global property
- GET_PROPERTY(INCLUDE_DIRS GLOBAL PROPERTY TESTS_INCLUDE_DIRS)
- GET_PROPERTY(TEST_INCLUDE_DIRS GLOBAL PROPERTY ${TARGET_NAME}_INCLUDE_DIRS)
- INCLUDE_DIRECTORIES(
- ${INCLUDE_DIRS}
- ${TEST_INCLUDE_DIRS}
- )
-
- # get library dirs global property
- GET_PROPERTY(LIBRARY_DIRS GLOBAL PROPERTY TESTS_LIBRARY_DIRS)
- GET_PROPERTY(TEST_LIBRARY_DIRS GLOBAL PROPERTY ${TARGET_NAME}_LIBRARY_DIRS)
- LINK_DIRECTORIES(
- ${LIBRARY_DIRS}
- ${TEST_LIBRARY_DIRS}
- )
-
- # get link libraries global property
- GET_PROPERTY(LINK_LIBRARIES GLOBAL PROPERTY TESTS_LIBRARIES)
- GET_PROPERTY(TEST_LIBRARIES GLOBAL PROPERTY ${TARGET_NAME}_LIBRARIES)
- TARGET_LINK_LIBRARIES("${TARGET_NAME}"
- ${LINK_LIBRARIES}
- ${TEST_LIBRARIES}
- )
-ENDFUNCTION(WRT_TEST_BUILD)
-
-FUNCTION(WRT_TEST_INSTALL)
- SET_TARGET_PROPERTIES(${ARGV} PROPERTIES
- BUILD_WITH_INSTALL_RPATH ON
- INSTALL_RPATH_USE_LINK_PATH ON
- )
- INSTALL(TARGETS ${ARGV}
- DESTINATION bin
- PERMISSIONS OWNER_READ
- OWNER_WRITE
- OWNER_EXECUTE
- GROUP_READ
- GROUP_EXECUTE
- WORLD_READ
- WORLD_EXECUTE
- )
-ENDFUNCTION(WRT_TEST_INSTALL)
-
-# Takes arbitrary number of arguments and concatenates them using ':' character.
-# Rationale:
-# CMake list when converted to a string is joined with ';' character. However,
-# GCC takes strings with multiple elements separated with ':' (e.g. list of
-# paths). Used typically when generating DB schemas with ORM mechanism.
-FUNCTION(WRT_CONVERT_TO_GCC_LIST OUTPUT_VARIABLE)
- FOREACH(ITEM ${ARGN})
- LIST(APPEND ITEMS ${ITEM})
- ENDFOREACH(ITEM)
- STRING(REPLACE ";" ":" OUTPUT "${ITEMS}")
- SET("${OUTPUT_VARIABLE}" "${OUTPUT}" PARENT_SCOPE)
-ENDFUNCTION(WRT_CONVERT_TO_GCC_LIST)
* limitations under the License.
*/
-#ifndef WRT_INSTALLER_TESTS_GENERAL_COMMON_INCLUDE_INSTALLER_WRAPPER_H
-#define WRT_INSTALLER_TESTS_GENERAL_COMMON_INCLUDE_INSTALLER_WRAPPER_H
+#ifndef WRT_INSTALLER_TESTS_GENERAL_INSTALLER_WRAPPER_H
+#define WRT_INSTALLER_TESTS_GENERAL_INSTALLER_WRAPPER_H
#include <string>
const InstallResult OtherError = -1;
const InstallResult Success = 0;
+const std::string miscWidgetsStuff = "/opt/share/widget/tests/installer/";
+
+struct Result {
+ bool m_exc;
+ bool m_exd;
+ bool m_exs;
+ std::string message;
+ Result(bool exc = false, bool exd = false, bool exs = false)
+ : m_exc(exc), m_exd(exd), m_exs(exs) {}
+};
+
InstallResult install(
const std::string& path,
std::string& tizenId,
}
-#endif//WRT_INSTALLER_TESTS_GENERAL_COMMON_INCLUDE_INSTALLER_WRAPPER_H
+#endif//WRT_INSTALLER_TESTS_GENERAL_INSTALLER_WRAPPER_H
* @brief Manifest file reading
*/
-#ifndef WRT_INSTALLER_TESTS_GENERAL_COMMON_INCLUDE_MANIFESTFILE_H
-#define WRT_INSTALLER_TESTS_GENERAL_COMMON_INCLUDE_MANIFESTFILE_H
+#ifndef WRT_INSTALLER_TESTS_GENERAL_MANIFESTFILE_H
+#define WRT_INSTALLER_TESTS_GENERAL_MANIFESTFILE_H
#include <string>
};
-#endif //WRT_INSTALLER_TESTS_GENERAL_COMMON_INCLUDE_MANIFESTFILE_H
+#endif //WRT_INSTALLER_TESTS_GENERAL_MANIFESTFILE_H
--- /dev/null
+/*
+ * Copyright (c) 2013 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+/**
+ * @file TestCases.cpp
+ * @author Karol Pawlowski (k.pawlowski@samsung.com)
+ * @author Tomasz Iwanek (t.iwanek@samsung.com)
+ * @version 1.0
+ * @brief Manifest installation test's bodies
+ */
+
+#include <string>
+#include <dpl/utils/wrt_utility.h>
+#include <dpl/test/test_runner.h>
+#include <InstallerWrapper.h>
+#include <ManifestFile.h>
+
+using namespace InstallerWrapper;
+
+////////////////////////////////////////////////////////////////////////////////
+
+RUNNER_TEST_GROUP_INIT(Manifest)
+
+/*
+Name: creatingManifestFile
+Description: Creation of manifest file by wrt-installer test
+Expected: file should be created and installed by wrt-installer. Content should
+ match expected values
+*/
+RUNNER_TEST(creatingManifestFile)
+{
+ const char * manifestPath = "/opt/share/packages/manifest01.xml";
+ /* This widget removal should stay here in case previous test run failed
+ * (so widget has not been uninstalled) */
+ uninstallByGuid("http://test.samsung.com/widget/manifestTest");
+ std::string tizenId;
+ RUNNER_ASSERT(install(miscWidgetsStuff + "widgets/manifest.wgt", tizenId)
+ == InstallerWrapper::Success);
+ RUNNER_ASSERT(WrtUtilFileExists(manifestPath));
+ ManifestFile mf(manifestPath);
+
+ Try
+ {
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/@package")
+ == "manifest01");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/@type")
+ == "wgt");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/@version")
+ == "1.0");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:label")
+ == "Manifest Example");
+
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:author/@email")
+ == "manifest@misc.test.create.desktop.com");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:author/@href")
+ == "http://misc.test.create.desktop.com");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:author")
+ == "Manifest");
+
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@appid")
+ == "manifest01");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@nodisplay")
+ == "false");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@type")
+ == "webapp");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@extraid")
+ == "http://test.samsung.com/widget/manifestTest");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@taskmanage")
+ == "true");
+
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:icon")
+ == "manifest01.png");
+
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[not(@xml:lang)]")
+ == "Manifest Example");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[@xml:lang='de_DE']")
+ == "Manifest Beispiel");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[@xml:lang='en_US']")
+ == "Manifest Example");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[@xml:lang='pl']")
+ == "Przykład Manifest");
+ RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[@xml:lang='pt_PT']")
+ == "Exemplo manifesto");
+ }
+ Catch(ManifestFile::ManifestParseError)
+ {
+ RUNNER_ASSERT_MSG(false,DPL::Exception::KnownExceptionToString(_rethrown_exception));
+ }
+ /* If test finished sucessfully than uninstall test widget */
+ uninstall(tizenId);
+}
--- /dev/null
+/*
+ * Copyright (c) 2013 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+/**
+ * @file TestCases.cpp
+ * @author Karol Pawlowski (k.pawlowski@samsung.com)
+ * @author Tomasz Iwanek (t.iwanek@samsung.com)
+ * @version 1.0
+ * @brief NPlugins installation test's bodies
+ */
+
+#include <string>
+#include <dpl/test/test_runner.h>
+#include <InstallerWrapper.h>
+
+using namespace InstallerWrapper;
+
+////////////////////////////////////////////////////////////////////////////////
+
+RUNNER_TEST_GROUP_INIT(NPluginsInstall)
+
+/*
+Name: pluginFilesAdded
+Description: Tests installation of plugins attached to widget
+Expected: widget should be succesfully installed
+*/
+RUNNER_TEST(pluginFilesAdded)
+{
+ std::string tizenId;
+ RUNNER_ASSERT(install(miscWidgetsStuff
+ + "widgets/inst_nplug_1.wgt", tizenId) == InstallerWrapper::Success);
+ uninstall(tizenId);
+}
+
+/*
+Name: emptyPluginsDir
+Description: Tests installation with empty 'plugins' directory
+Expected: widget should be not installed
+*/
+RUNNER_TEST(emptyPluginsDir)
+{
+ std::string tizenId;
+ if(install(miscWidgetsStuff + "widgets/inst_nplug_2.wgt",
+ tizenId) == InstallerWrapper::Success) {
+ uninstall(tizenId);
+ RUNNER_ASSERT_MSG(false, "Invalid widget package installed");
+ }
+}
+
+/*
+Name: pluginFileAndOtherFile
+Description: Tests installation with plugins directory and data files
+Expected: widget should be installed
+*/
+RUNNER_TEST(pluginFileAndOtherFile)
+{
+ std::string tizenId;
+ RUNNER_ASSERT(install(miscWidgetsStuff
+ + "widgets/inst_nplug_3.wgt", tizenId) == InstallerWrapper::Success);
+ uninstall(tizenId);
+}
+
+/*
+Name: pluginFileAndSubdir
+Description: Tests installation with 'plugins' directory and subdirectories
+ inside plugin directory
+Expected: widget should be not installed
+*/
+RUNNER_TEST(pluginFileAndSubdir)
+{
+ std::string tizenId;
+ if(install(miscWidgetsStuff + "widgets/inst_nplug_4.wgt",
+ tizenId) == InstallerWrapper::Success) {
+ uninstall(tizenId);
+ RUNNER_ASSERT_MSG(false, "Invalid widget package installed");
+ }
+}
--- /dev/null
+/*
+ * Copyright (c) 2013 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+/**
+ * @file TestCases.cpp
+ * @author Karol Pawlowski (k.pawlowski@samsung.com)
+ * @author Tomasz Iwanek (t.iwanek@samsung.com)
+ * @version 1.0
+ * @brief Non root user installation test's bodies
+ */
+
+#include <string>
+#include <dpl/test/test_runner.h>
+#include <InstallerWrapper.h>
+
+using namespace InstallerWrapper;
+
+////////////////////////////////////////////////////////////////////////////////
+
+RUNNER_TEST_GROUP_INIT(NonRootUser)
+
+/*
+Name: widgetNonRootInstallation
+Description: Check installation from other user than root
+Expected: widget should be installed
+*/
+RUNNER_TEST(widgetNonRootInstallation)
+{
+ std::string tizenId;
+ RUNNER_ASSERT(install(
+ miscWidgetsStuff + "widgets/nonroot.wgt",
+ tizenId,
+ "app") == InstallerWrapper::Success);
+ uninstall(tizenId);
+}
--- /dev/null
+/*
+ * Copyright (c) 2013 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+/**
+ * @file TestCases.cpp
+ * @author Karol Pawlowski (k.pawlowski@samsung.com)
+ * @author Andrzej Surdej (a.surdej@samsung.com)
+ * @version 1.0
+ * @brief Parsing Tizen Appservice test's bodies
+ */
+
+#include <string>
+#include <algorithm>
+#include <dpl/test/test_runner.h>
+#include <dpl/wrt-dao-ro/widget_dao_read_only.h>
+#include <InstallerWrapper.h>
+
+using namespace InstallerWrapper;
+
+////////////////////////////////////////////////////////////////////////////////
+
+RUNNER_TEST_GROUP_INIT(ParsingTizenAppservice)
+
+/*
+Name: correct_csp_policy
+Description: Tests if widget policy is correctly parsed from config file
+ and stored into database
+Expected: widget should be installed and policy should mach
+*/
+RUNNER_TEST(tizen_appservice_disposition)
+{
+ std::string tizenId;
+ RUNNER_ASSERT(install(miscWidgetsStuff + "widgets/appservice_dispos.wgt",
+ tizenId) == InstallerWrapper::Success);
+
+ WrtDB::WidgetDAOReadOnly dao(DPL::FromASCIIString(tizenId));
+ WidgetApplicationServiceList appsvcList;
+ dao.getAppServiceList(appsvcList);
+ uninstall(tizenId);
+
+ RUNNER_ASSERT_MSG(appsvcList.size() == 4, "Incorrect list size");
+ WidgetApplicationService s;
+ s.src = DPL::FromUTF8String("edit1.html");
+ s.operation = DPL::FromUTF8String("http://tizen.org/appsvc/operation/edit");
+ s.mime = DPL::FromUTF8String("image/jpg"); /* mime type */
+ s.disposition = WidgetApplicationService::Disposition::WINDOW;
+ RUNNER_ASSERT_MSG(
+ std::find(appsvcList.begin(), appsvcList.end(), s) != appsvcList.end(),
+ "Unable to find service #");
+
+ s.src = DPL::FromUTF8String("edit2.html");
+ s.operation = DPL::FromUTF8String("http://tizen.org/appsvc/operation/view");
+ s.mime = DPL::FromUTF8String("audio/ogg"); /* mime type */
+ s.disposition = WidgetApplicationService::Disposition::WINDOW;
+ RUNNER_ASSERT_MSG(
+ std::find(appsvcList.begin(), appsvcList.end(), s) != appsvcList.end(),
+ "Unable to find service ##");
+
+ s.src = DPL::FromUTF8String("edit3.html");
+ s.operation = DPL::FromUTF8String("http://tizen.org/appsvc/operation/call");
+ s.mime = DPL::FromUTF8String("image/png"); /* mime type */
+ s.disposition = WidgetApplicationService::Disposition::INLINE;
+ RUNNER_ASSERT_MSG(
+ std::find(appsvcList.begin(), appsvcList.end(), s) != appsvcList.end(),
+ "Unable to find service ###");
+
+ s.src = DPL::FromUTF8String("edit4.html");
+ s.operation = DPL::FromUTF8String("http://tizen.org/appsvc/operation/send");
+ s.mime = DPL::FromUTF8String("text/css"); /* mime type */
+ s.disposition = WidgetApplicationService::Disposition::WINDOW;
+ RUNNER_ASSERT_MSG(
+ std::find(appsvcList.begin(), appsvcList.end(), s) != appsvcList.end(),
+ "Unable to find service ####");
+}
+++ /dev/null
-/*
- * Copyright (c) 2013 Samsung Electronics Co., Ltd All Rights Reserved
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-/**
- * @file TestCases.cpp
- * @author Karol Pawlowski (k.pawlowski@samsung.com)
- * @author Tomasz Iwanek (t.iwanek@samsung.com)
- * @version 1.0
- * @brief Miscellaneous test's bodies
- */
-
-#include <string>
-#include <algorithm>
-#include <dpl/utils/wrt_utility.h>
-#include <dpl/test/test_runner.h>
-#include <dpl/wrt-dao-ro/widget_dao_read_only.h>
-#include <dpl/log/log.h>
-#include <InstallerWrapper.h>
-#include <ManifestFile.h>
-
-using namespace InstallerWrapper;
-
-namespace {
-
-const std::string miscWidgetsStuff = "/opt/share/widget/tests/installer/";
-
-struct Result {
- bool m_exc;
- bool m_exd;
- bool m_exs;
- std::string message;
- Result(bool exc = false, bool exd = false, bool exs = false)
- : m_exc(exc), m_exd(exd), m_exs(exs) {}
-};
-
-}
-
-////////////////////////////////////////////////////////////////////////////////
-
-RUNNER_TEST_GROUP_INIT(Manifest)
-
-/*
-Name: creatingManifestFile
-Description: Creation of manifest file by wrt-installer test
-Expected: file should be created and installed by wrt-installer. Content should
- match expected values
-*/
-RUNNER_TEST(creatingManifestFile)
-{
- const char * manifestPath = "/opt/share/packages/manifest01.xml";
- /* This widget removal should stay here in case previous test run failed
- * (so widget has not been uninstalled) */
- uninstallByGuid("http://test.samsung.com/widget/manifestTest");
- std::string tizenId;
- RUNNER_ASSERT(install(miscWidgetsStuff + "widgets/manifest.wgt", tizenId)
- == InstallerWrapper::Success);
- RUNNER_ASSERT(WrtUtilFileExists(manifestPath));
- ManifestFile mf(manifestPath);
-
- Try
- {
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/@package")
- == "manifest01");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/@type")
- == "wgt");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/@version")
- == "1.0");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:label")
- == "Manifest Example");
-
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:author/@email")
- == "manifest@misc.test.create.desktop.com");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:author/@href")
- == "http://misc.test.create.desktop.com");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:author")
- == "Manifest");
-
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@appid")
- == "manifest01");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@nodisplay")
- == "false");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@type")
- == "webapp");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@extraid")
- == "http://test.samsung.com/widget/manifestTest");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/@taskmanage")
- == "true");
-
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:icon")
- == "manifest01.png");
-
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[not(@xml:lang)]")
- == "Manifest Example");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[@xml:lang='de_DE']")
- == "Manifest Beispiel");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[@xml:lang='en_US']")
- == "Manifest Example");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[@xml:lang='pl']")
- == "Przykład Manifest");
- RUNNER_ASSERT(mf.getValueByXpath("/p:manifest/p:ui-application/p:label[@xml:lang='pt_PT']")
- == "Exemplo manifesto");
- }
- Catch(ManifestFile::ManifestParseError)
- {
- RUNNER_ASSERT_MSG(false,DPL::Exception::KnownExceptionToString(_rethrown_exception));
- }
- /* If test finished sucessfully than uninstall test widget */
- uninstall(tizenId);
-}
-
-////////////////////////////////////////////////////////////////////////////////
-
-RUNNER_TEST_GROUP_INIT(BackgroundPage)
-
-/*
-Name: widgetWithBackgroundPage
-Description: Tests if widget with background page is installed correctly
-Expected: widget should be installed correctly
-*/
-RUNNER_TEST(widgetWithBackgroundPage)
-{
- std::string tizenId;
- RUNNER_ASSERT(install(miscWidgetsStuff + "widgets/bg-00-with_bg.wgt",
- tizenId) == InstallerWrapper::Success);
- uninstall(tizenId);
-}
-
-/*
-Name: missingBackgroundFile
-Description: Tests if widget with declared in conifg background page
- but missing background file will be installed correctly.
-Expected: widget should NOT be installed
-*/
-RUNNER_TEST(missingBackgroundFile)
-{
- std::string tizenId;
- if(install(miscWidgetsStuff + "widgets/bg-01-missing_file.wgt",
- tizenId) == InstallerWrapper::Success) {
- uninstall(tizenId);
- RUNNER_ASSERT_MSG(false, "Invalid widget package installed");
- }
-}
-
-/*
-Name: widgetWithoutBackgroundPage
-Description: Complementary test to check if normal widget\
- without background page is successfully installed
-Expected: widget should be installed
-*/
-RUNNER_TEST(widgetWithoutBackgroundPage)
-{
- std::string tizenId;
- RUNNER_ASSERT(install(miscWidgetsStuff + "widgets/bg-02-without_bg.wgt",
- tizenId) == InstallerWrapper::Success);
- uninstall(tizenId);
-}
-
-////////////////////////////////////////////////////////////////////////////////
-
-RUNNER_TEST_GROUP_INIT(NonRootUser)
-
-/*
-Name: widgetNonRootInstallation
-Description: Check installation from other user than root
-Expected: widget should be installed
-*/
-RUNNER_TEST(widgetNonRootInstallation)
-{
- std::string tizenId;
- RUNNER_ASSERT(install(
- miscWidgetsStuff + "widgets/nonroot.wgt",
- tizenId,
- "app") == InstallerWrapper::Success);
- uninstall(tizenId);
-}
-
-////////////////////////////////////////////////////////////////////////////////
-
-RUNNER_TEST_GROUP_INIT(NPluginsInstall)
-
-/*
-Name: pluginFilesAdded
-Description: Tests installation of plugins attached to widget
-Expected: widget should be succesfully installed
-*/
-RUNNER_TEST(pluginFilesAdded)
-{
- std::string tizenId;
- RUNNER_ASSERT(install(miscWidgetsStuff
- + "widgets/inst_nplug_1.wgt", tizenId) == InstallerWrapper::Success);
- uninstall(tizenId);
-}
-
-/*
-Name: emptyPluginsDir
-Description: Tests installation with empty 'plugins' directory
-Expected: widget should be not installed
-*/
-RUNNER_TEST(emptyPluginsDir)
-{
- std::string tizenId;
- if(install(miscWidgetsStuff + "widgets/inst_nplug_2.wgt",
- tizenId) == InstallerWrapper::Success) {
- uninstall(tizenId);
- RUNNER_ASSERT_MSG(false, "Invalid widget package installed");
- }
-}
-
-/*
-Name: pluginFileAndOtherFile
-Description: Tests installation with plugins directory and data files
-Expected: widget should be installed
-*/
-RUNNER_TEST(pluginFileAndOtherFile)
-{
- std::string tizenId;
- RUNNER_ASSERT(install(miscWidgetsStuff
- + "widgets/inst_nplug_3.wgt", tizenId) == InstallerWrapper::Success);
- uninstall(tizenId);
-}
-
-/*
-Name: pluginFileAndSubdir
-Description: Tests installation with 'plugins' directory and subdirectories
- inside plugin directory
-Expected: widget should be not installed
-*/
-RUNNER_TEST(pluginFileAndSubdir)
-{
- std::string tizenId;
- if(install(miscWidgetsStuff + "widgets/inst_nplug_4.wgt",
- tizenId) == InstallerWrapper::Success) {
- uninstall(tizenId);
- RUNNER_ASSERT_MSG(false, "Invalid widget package installed");
- }
-}
-
-RUNNER_TEST_GROUP_INIT(ParsingTizenAppservice)
-namespace {
-
-}
-
-/*
-Name: correct_csp_policy
-Description: Tests if widget policy is correctly parsed from config file
- and stored into database
-Expected: widget should be installed and policy should mach
-*/
-RUNNER_TEST(tizen_appservice_disposition)
-{
- std::string tizenId;
- RUNNER_ASSERT(install(miscWidgetsStuff + "widgets/appservice_dispos.wgt",
- tizenId) == InstallerWrapper::Success);
-
- WrtDB::WidgetDAOReadOnly dao(DPL::FromASCIIString(tizenId));
- WidgetApplicationServiceList appsvcList;
- dao.getAppServiceList(appsvcList);
- uninstall(tizenId);
-
- RUNNER_ASSERT_MSG(appsvcList.size() == 4, "Incorrect list size");
- WidgetApplicationService s;
- s.src = DPL::FromUTF8String("edit1.html");
- s.operation = DPL::FromUTF8String("http://tizen.org/appsvc/operation/edit");
- s.mime = DPL::FromUTF8String("image/jpg"); /* mime type */
- s.disposition = WidgetApplicationService::Disposition::WINDOW;
- RUNNER_ASSERT_MSG(
- std::find(appsvcList.begin(), appsvcList.end(), s) != appsvcList.end(),
- "Unable to find service #");
-
- s.src = DPL::FromUTF8String("edit2.html");
- s.operation = DPL::FromUTF8String("http://tizen.org/appsvc/operation/view");
- s.mime = DPL::FromUTF8String("audio/ogg"); /* mime type */
- s.disposition = WidgetApplicationService::Disposition::WINDOW;
- RUNNER_ASSERT_MSG(
- std::find(appsvcList.begin(), appsvcList.end(), s) != appsvcList.end(),
- "Unable to find service ##");
-
- s.src = DPL::FromUTF8String("edit3.html");
- s.operation = DPL::FromUTF8String("http://tizen.org/appsvc/operation/call");
- s.mime = DPL::FromUTF8String("image/png"); /* mime type */
- s.disposition = WidgetApplicationService::Disposition::INLINE;
- RUNNER_ASSERT_MSG(
- std::find(appsvcList.begin(), appsvcList.end(), s) != appsvcList.end(),
- "Unable to find service ###");
-
- s.src = DPL::FromUTF8String("edit4.html");
- s.operation = DPL::FromUTF8String("http://tizen.org/appsvc/operation/send");
- s.mime = DPL::FromUTF8String("text/css"); /* mime type */
- s.disposition = WidgetApplicationService::Disposition::WINDOW;
- RUNNER_ASSERT_MSG(
- std::find(appsvcList.begin(), appsvcList.end(), s) != appsvcList.end(),
- "Unable to find service ####");
-}
* @file TestInit.cpp
* @author Tomasz Iwanek (t.iwanek@samsung.com)
* @version 1.0
- * @brief main for misc tests
+ * @brief Main for wrt-installer general tests
*/
#include <dpl/test/test_runner.h>
+++ /dev/null
-# Copyright (c) 2013 Samsung Electronics Co., Ltd All Rights Reserved
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-# @file CMakeLists.txt
-# @author Tomasz Iwanek (t.iwanek@samsung.com)
-# @author Karol Pawlowski (k.pawlowski@samsung.com)
-# @version 1.0
-# @brief
-#
-
-SET(COMMON_INCLUDES "${CMAKE_CURRENT_SOURCE_DIR}/include")
-
-WRT_TEST_LIBRARY(${WRT_TEST_LIBRARY})
-
-WRT_INCLUDE_DIRECTORIES(
- ${COMMON_LIB_PKGS_INCLUDE_DIRS}
- ${COMMON_INCLUDES}
- )
-WRT_LINK_DIRECTORIES(${COMMON_LIB_PKGS_LIBRARY_DIRS})
-WRT_TARGET_LINK_LIBRARIES(${COMMON_LIB_PKGS_LIBRARIES})
-
-SET(WRT_DETAIL_SOURCES
- ${CMAKE_CURRENT_SOURCE_DIR}/src/InstallerWrapper.cpp
- ${CMAKE_CURRENT_SOURCE_DIR}/src/ManifestFile.cpp
-)
-
-INCLUDE_DIRECTORIES(${COMMON_INCLUDES})
-INCLUDE_DIRECTORIES(${COMMON_LIB_PKGS_INCLUDE_DIRS})
-
-ADD_LIBRARY(${WRT_TEST_LIBRARY} STATIC ${WRT_DETAIL_SOURCES})