mirror of
https://github.com/D00Med/scifi_nodes.git
synced 2025-06-29 14:40:55 +02:00
Compare commits
1 Commits
integratio
...
contributo
Author | SHA1 | Date | |
---|---|---|---|
ea96dd7c05 |
15
.github/workflows/integration-test.yml
vendored
15
.github/workflows/integration-test.yml
vendored
@ -1,15 +0,0 @@
|
|||||||
name: integration-test
|
|
||||||
|
|
||||||
on: [push, pull_request]
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
timeout-minutes: 10
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v1
|
|
||||||
|
|
||||||
- name: integration-test
|
|
||||||
run: ./test/integration-test.sh
|
|
@ -3,7 +3,6 @@
|
|||||||
# scifi_nodes
|
# scifi_nodes
|
||||||
|
|
||||||

|

|
||||||

|
|
||||||
|
|
||||||
Minetest mod that adds scifi themed blocks, doors, materials, plants and other assets.
|
Minetest mod that adds scifi themed blocks, doors, materials, plants and other assets.
|
||||||
|
|
||||||
@ -43,9 +42,13 @@ CC0
|
|||||||
|
|
||||||
# Contributors:
|
# Contributors:
|
||||||
|
|
||||||
|
* D00Med https://github.com/D00Med (creator)
|
||||||
* tanmayameher https://github.com/tanmayameher
|
* tanmayameher https://github.com/tanmayameher
|
||||||
* naturefreshmilk https://github.com/naturefreshmilk
|
* BuckarooBanzay https://github.com/BuckarooBanzay
|
||||||
* acmgit https://github.com/acmgit
|
* acmgit https://github.com/acmgit
|
||||||
* catz85 https://github.com/catz85
|
* catz85 https://github.com/catz85
|
||||||
* coil0 https://github.com/coil0
|
* coil0 https://github.com/coil0
|
||||||
* Grossam https://github.com/Grossam
|
* Grossam https://github.com/Grossam
|
||||||
|
* OgelGames https://github.com/OgelGames
|
||||||
|
* leftshift https://github.com/leftshift
|
||||||
|
* fluxionary https://github.com/fluxionary
|
||||||
|
@ -1,25 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
# Spins up a test world to ensure proper working recipes and registrations
|
|
||||||
|
|
||||||
CWD=$(dirname $0)
|
|
||||||
cd ${CWD}/../
|
|
||||||
|
|
||||||
CFG=/tmp/minetest.conf
|
|
||||||
MTDIR=/tmp/mt
|
|
||||||
WORLDDIR=${MTDIR}/worlds/world
|
|
||||||
|
|
||||||
cat <<EOF > ${CFG}
|
|
||||||
# empty
|
|
||||||
EOF
|
|
||||||
|
|
||||||
mkdir -p ${WORLDDIR}
|
|
||||||
chmod 777 ${MTDIR} -R
|
|
||||||
docker run --rm -i \
|
|
||||||
-v ${CFG}:/etc/minetest/minetest.conf:ro \
|
|
||||||
-v ${MTDIR}:/var/lib/minetest/.minetest \
|
|
||||||
-v $(pwd)/:/var/lib/minetest/.minetest/worlds/world/worldmods/scifi_nodes \
|
|
||||||
-v $(pwd)/test/test_mod/:/var/lib/minetest/.minetest/worlds/world/worldmods/scifi_nodes_test \
|
|
||||||
--network host \
|
|
||||||
registry.gitlab.com/minetest/minetest/server:5.2.0
|
|
||||||
|
|
||||||
test -f ${WORLDDIR}/integration_test.json && exit 0 || exit 1
|
|
@ -1,40 +0,0 @@
|
|||||||
|
|
||||||
minetest.log("warning", "[TEST] integration-test enabled!")
|
|
||||||
|
|
||||||
-- those mods have to be present
|
|
||||||
local assert_mods = {
|
|
||||||
"scifi_nodes"
|
|
||||||
}
|
|
||||||
|
|
||||||
-- those nodes have to be present
|
|
||||||
local assert_nodes = {
|
|
||||||
"scifi_nodes:crate",
|
|
||||||
"scifi_nodes:door1a"
|
|
||||||
}
|
|
||||||
|
|
||||||
minetest.register_on_mods_loaded(function()
|
|
||||||
minetest.after(0, function()
|
|
||||||
-- check mods
|
|
||||||
for _, modname in ipairs(assert_mods) do
|
|
||||||
if not minetest.get_modpath(modname) then
|
|
||||||
error("Mod not present: " .. modname)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
-- check nodes
|
|
||||||
for _, nodename in ipairs(assert_nodes) do
|
|
||||||
if not minetest.registered_nodes[nodename] then
|
|
||||||
error("Node not present: " .. nodename)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
local data = minetest.write_json({ success = true }, true);
|
|
||||||
local file = io.open(minetest.get_worldpath().."/integration_test.json", "w" );
|
|
||||||
if file then
|
|
||||||
file:write(data)
|
|
||||||
file:close()
|
|
||||||
end
|
|
||||||
minetest.request_shutdown("success")
|
|
||||||
|
|
||||||
end)
|
|
||||||
end)
|
|
@ -1,2 +0,0 @@
|
|||||||
name = scifi_nodes_test
|
|
||||||
depends = scifi_nodes
|
|
Reference in New Issue
Block a user