diff options
| author | ruki <[email protected]> | 2020-04-29 22:40:16 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2020-04-29 10:01:40 +0800 |
| commit | f046445a06a09743d37e731c91918be2dc7f4c65 (patch) | |
| tree | a269531b8f3f12c777d4f64879f77223671cafc7 /tests | |
| parent | 1902b2515b884f4af7db49bc6ddcd0e0224369c2 (diff) | |
fix tests
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/plugins/create/test.lua | 17 | ||||
| -rw-r--r-- | tests/projects/other/build_deps/xmake.lua | 7 | ||||
| -rw-r--r-- | tests/projects/rust/static_library/xmake.lua | 3 |
3 files changed, 16 insertions, 11 deletions
diff --git a/tests/plugins/create/test.lua b/tests/plugins/create/test.lua index 83676b2ef..397f846f4 100644 --- a/tests/plugins/create/test.lua +++ b/tests/plugins/create/test.lua @@ -1,10 +1,11 @@ function main () - os.exec("xmake create -P $(tmpdir)/test") - os.exec("xmake -P $(tmpdir)/test") - os.exec("xmake create -l c++ -P $(tmpdir)/test_cpp") - os.exec("xmake -P $(tmpdir)/test_cpp") - os.exec("xmake create -l c++ -t static -P $(tmpdir)/test_cpp2") - os.exec("xmake -P $(tmpdir)/test_cpp2") - os.exec("xmake create -l c++ -t shared -P $(tmpdir)/test_cpp3") - os.exec("xmake -P $(tmpdir)/test_cpp3") + os.tryrm("$(tmpdir)/test_create") + os.exec("xmake create -P $(tmpdir)/test_create/test") + os.exec("xmake -P $(tmpdir)/test_create/test") + os.exec("xmake create -l c++ -P $(tmpdir)/test_create/test_cpp") + os.exec("xmake -P $(tmpdir)/test_create/test_cpp") + os.exec("xmake create -l c++ -t static -P $(tmpdir)/test_create/test_cpp2") + os.exec("xmake -P $(tmpdir)/test_create/test_cpp2") + os.exec("xmake create -l c++ -t shared -P $(tmpdir)/test_create/test_cpp3") + os.exec("xmake -P $(tmpdir)/test_create/test_cpp3") end diff --git a/tests/projects/other/build_deps/xmake.lua b/tests/projects/other/build_deps/xmake.lua index 696040c71..c7beeaa59 100644 --- a/tests/projects/other/build_deps/xmake.lua +++ b/tests/projects/other/build_deps/xmake.lua @@ -14,6 +14,7 @@ target("dep1") after_link(function (target) assert(os.isfile(target:targetfile()), "dep1: after_link failed!") end) + on_install(function (target) end) target("dep2") set_kind("static") @@ -29,6 +30,7 @@ target("dep2") after_link(function (target) assert(os.isfile(target:targetfile()), "dep2: after_link failed!") end) + on_install(function (target) end) target("dep3") set_kind("static") @@ -44,6 +46,7 @@ target("dep3") assert(os.isfile(target:dep("dep4"):targetfile()), "dep3: after_link failed!") assert(os.isfile(target:dep("dep5"):targetfile()), "dep3: after_link failed!") end) + on_install(function (target) end) target("dep4") set_kind("static") @@ -54,6 +57,7 @@ target("dep4") after_link(function (target) assert(os.isfile(target:targetfile()), "dep4: after_link failed!") end) + on_install(function (target) end) target("dep5") set_kind("static") @@ -64,6 +68,7 @@ target("dep5") after_link(function (target) assert(os.isfile(target:targetfile()), "dep5: after_link failed!") end) + on_install(function (target) end) target("test1") set_kind("binary") @@ -83,6 +88,7 @@ target("test1") after_link(function (target) assert(os.isfile(target:targetfile()), "test1: after_link failed!") end) + on_install(function (target) end) target("test2") set_kind("binary") @@ -100,3 +106,4 @@ target("test2") after_link(function (target) assert(os.isfile(target:targetfile()), "test2: after_link failed!") end) + on_install(function (target) end) diff --git a/tests/projects/rust/static_library/xmake.lua b/tests/projects/rust/static_library/xmake.lua index f66f48b0f..5ae884d1a 100644 --- a/tests/projects/rust/static_library/xmake.lua +++ b/tests/projects/rust/static_library/xmake.lua @@ -22,7 +22,4 @@ target("test") -- add files add_files("src/main.rs") - -- add link directory - add_linkdirs("$(buildir)/$(mode)/$(arch)") - |
