diff --git a/CMakeLists.txt b/CMakeLists.txt index 141fd94..3f6bd31 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -78,17 +78,6 @@ link_directories(${LIBLOOT_EXTRACTED_PATH}) set(LIBLOOT_STATIC_LIBRARY "${CMAKE_STATIC_LIBRARY_PREFIX}loot${CMAKE_STATIC_LIBRARY_SUFFIX}") set(LIBLOOT_SHARED_LIBRARY "${CMAKE_SHARED_LIBRARY_PREFIX}loot${CMAKE_SHARED_LIBRARY_SUFFIX}") -####################################### -# Test Masterlist -####################################### - -ExternalProject_Add(test-masterlist - PREFIX "external" - URL "https://github.com/loot/oblivion/archive/7f125ae4464224ff785111c7667c2cff85c896ec.zip" - CONFIGURE_COMMAND "" - BUILD_COMMAND "" - INSTALL_COMMAND "") - ####################################### # Python Module ####################################### @@ -97,7 +86,7 @@ pybind11_add_module(loot_api "${CMAKE_SOURCE_DIR}/src/main.cpp" "${CMAKE_SOURCE_DIR}/src/convenience.cpp" "${CMAKE_BINARY_DIR}/generated/wrapper_version.cpp") -add_dependencies(loot_api libloot test-masterlist) +add_dependencies(loot_api libloot) if (CMAKE_SYSTEM_NAME MATCHES "Windows") target_link_libraries(loot_api PRIVATE ${LIBLOOT_STATIC_LIBRARY}) @@ -117,14 +106,7 @@ add_custom_command(TARGET loot_api POST_BUILD "${LIBLOOT_EXTRACTED_PATH}/${LIBLOOT_SHARED_LIBRARY}" "$/${LIBLOOT_SHARED_LIBRARY}") -# Copy the test masterlist to the build directory. -ExternalProject_Get_Property(test-masterlist SOURCE_DIR) -add_custom_command(TARGET loot_api POST_BUILD - COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${SOURCE_DIR}/masterlist.yaml" - "$/masterlist.yaml") - -# Also copy the test Python script to the build directory. +# Copy the test Python script to the build directory. add_custom_command(TARGET loot_api POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different "${CMAKE_SOURCE_DIR}/src/test.py" diff --git a/src/test.py b/src/test.py index 071a30d..a9f3f65 100644 --- a/src/test.py +++ b/src/test.py @@ -63,7 +63,7 @@ class TestLootApi(GameFixture): self.assertNotEqual(db, None) class TestDatabaseInterface(GameFixture): - masterlist_path = u'masterlist.yaml' + masterlist_path = u'../../test/masterlist.yaml' def setUp(self): super(TestDatabaseInterface, self).setUp() diff --git a/test/masterlist.yaml b/test/masterlist.yaml new file mode 100644 index 0000000..106dff3 --- /dev/null +++ b/test/masterlist.yaml @@ -0,0 +1,30 @@ +plugins: + - name: Oblivion.esm + msg: + - type: error + content: 'This must not be activated. However, it can be useful when porting Oblivion mods to Nehrim.' + + - name: Unofficial Oblivion Patch.esp + tag: + - Actors.ACBS + - Actors.AIData + - Actors.AIPackages + - Actors.CombatStyle + - Actors.DeathItem + - Actors.Stats + - C.Climate + - C.Light + - C.Music + - C.Name + - C.Owner + - Creatures.Blood + - Delev + - Factions + - Invent + - Names + - NPC.Class + - Relations + - Relev + - Scripts + - Stats + - -C.Water