Add simple initialization test (#15)
* Add simple initialization test * Exclude spec from luacheck Co-authored-by: SX <sx@minetest>
This commit is contained in:
parent
5e22da6fdb
commit
ccc26a5d80
22
.github/workflows/mineunit.yml
vendored
Normal file
22
.github/workflows/mineunit.yml
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
|
||||
name: mineunit
|
||||
|
||||
on: [push, pull_request]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- id: mineunit
|
||||
uses: mt-mods/mineunit-actions@master
|
||||
with:
|
||||
badge-label: Test coverage
|
||||
# Uncomment to add coverage badge for regression tests
|
||||
# - uses: RubbaBoy/BYOB@v1.2.0
|
||||
# with:
|
||||
# NAME: "${{ steps.mineunit.outputs.badge-name }}"
|
||||
# LABEL: "${{ steps.mineunit.outputs.badge-label }}"
|
||||
# STATUS: "${{ steps.mineunit.outputs.badge-status }}"
|
||||
# COLOR: "${{ steps.mineunit.outputs.badge-color }}"
|
||||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
@ -20,3 +20,7 @@ read_globals = {
|
||||
"mesecon",
|
||||
"screwdriver",
|
||||
}
|
||||
|
||||
exclude_files = {
|
||||
"**/spec/**",
|
||||
}
|
||||
|
1
spec/fixtures/digilines.lua
vendored
Normal file
1
spec/fixtures/digilines.lua
vendored
Normal file
@ -0,0 +1 @@
|
||||
digilines = {}
|
13
spec/init_spec.lua
Normal file
13
spec/init_spec.lua
Normal file
@ -0,0 +1,13 @@
|
||||
require("mineunit")
|
||||
|
||||
mineunit("core")
|
||||
|
||||
fixture("digilines")
|
||||
|
||||
describe("Digistuff mod initialization", function()
|
||||
|
||||
it("will not fail", function()
|
||||
sourcefile("init")
|
||||
end)
|
||||
|
||||
end)
|
1
spec/mineunit.conf
Normal file
1
spec/mineunit.conf
Normal file
@ -0,0 +1 @@
|
||||
modname = "digistuff"
|
Loading…
x
Reference in New Issue
Block a user