Use mineunit for advtrains_*

This commit is contained in:
Y. Wang 2022-05-05 21:04:23 +02:00
parent 5c8962b39b
commit 9d5205e7e2
No known key found for this signature in database
GPG Key ID: 54A05DDF18D7A0EB
1 changed files with 13 additions and 7 deletions

View File

@ -5,7 +5,8 @@ packages:
- minetest-server
- unzip
- wget
- lua-busted
- lua5.1
- luarocks
sources :
- https://git.sr.ht/~gpcf/advtrains
@ -28,13 +29,18 @@ tasks:
curl https://lifomaps.de/advtrains-test/testworld.tar.gz -o ~/testworld.tar.gz
cd .minetest/worlds/
tar xf ../../testworld.tar.gz
- install_mineunit : |
for i in {busted,luacov}; do
luarocks install --local --lua-version 5.1 $i >/dev/null
done
luarocks install --local --lua-version 5.1 --server=https://luarocks.org/dev mineunit
- run_unit_tests : |
cd advtrains/advtrains
busted
cd ../advtrains_interlocking
busted
cd ../serialize_lib
busted
cd advtrains/serialize_lib
~/.luarocks/bin/busted
for i in {advtrains,advtrains_interlocking}; do
cd ../$i
~/.luarocks/bin/mineunit
done
- activate_test_env: |
cd advtrains
git merge --no-commit origin/luaatcdebug