diff --git a/tests/NTest/NTest.md b/tests/NTest/NTest.md index 98b11fed9a..6aa3425b47 100644 --- a/tests/NTest/NTest.md +++ b/tests/NTest/NTest.md @@ -3,7 +3,7 @@ | :----- | :-------------------- | :---------- | :------ | | 2020-11-01 | [Gregor Hartmann](https://github.com/HHHartmann) | [Gregor Hartmann](https://github.com/HHHartmann) | [NTest.lua](NTest.lua) | -NTest is a test system for NodeMCU which is originally based on gambiarra. It is designed to run on chip but also runs on the host using luac.cross. +NTest is a test system for NodeMCU which is originally based on gambiarra. It is designed to run on chip but the selftest also runs on the host using luac.cross. !!! attention You will have to use LFS to run this as it is too big to fit in memory. diff --git a/tests/NTest/NTest_test.lua b/tests/NTest/NTest_NTest.lua similarity index 100% rename from tests/NTest/NTest_test.lua rename to tests/NTest/NTest_NTest.lua diff --git a/tests/NTest/tests/file.lua b/tests/NTest_file.lua similarity index 95% rename from tests/NTest/tests/file.lua rename to tests/NTest_file.lua index 284dcea790..2d3e4fef3b 100644 --- a/tests/NTest/tests/file.lua +++ b/tests/NTest_file.lua @@ -9,12 +9,6 @@ local function cleanup() end end -local function buildfn(fn, ...) - local params = {...} - local fnp = function() fn(unpack(params)) end - return fnp -end - N.test('exist', function() cleanup() nok(file.exists("non existing file"), "non existing file") @@ -170,8 +164,6 @@ N.test('open non existing', function() testopen(nok, "testfile", "r+") testopen(ok, "testfile", "w+") testopen(ok, "testfile", "a+") - - --fail(buildfn(file.open, "testfile"), "errormsg", "x") -- shouldn't this fail? end) N.test('open existing', function() @@ -190,8 +182,6 @@ N.test('open existing', function() testopen("r+", 0) testopen("w+", 0) testopen("a+", 11) - - --fail(buildfn(file.open, "testfile"), "errormsg", "x") -- shouldn't this fail? end) N.test('remove', function() diff --git a/tests/NTest/tests/tmr.lua b/tests/NTest_tmr.lua similarity index 100% rename from tests/NTest/tests/tmr.lua rename to tests/NTest_tmr.lua