diff options
Diffstat (limited to 'spec/quick/test.q')
| -rw-r--r-- | spec/quick/test.q | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/spec/quick/test.q b/spec/quick/test.q new file mode 100644 index 0000000..cb5ccd7 --- /dev/null +++ b/spec/quick/test.q @@ -0,0 +1,51 @@ +================================================================================ +TEST: luarocks test: handle if test.command is not a string + +Regression test for #1055. + +FILE: example-1.0-1.rockspec +-------------------------------------------------------------------------------- +rockspec_format = "3.0" +source = { + url = "", +} +package = "example" +version = "1.0-1" +test = { + type = "command", + command = {"./unit.lua"}, +} +-------------------------------------------------------------------------------- + +RUN: luarocks test +EXIT: 1 +STDERR: +-------------------------------------------------------------------------------- +'command' expects a string +-------------------------------------------------------------------------------- + + + +================================================================================ +TEST: luarocks test: handle if test.script is not a string + +FILE: example-1.0-1.rockspec +-------------------------------------------------------------------------------- +rockspec_format = "3.0" +source = { + url = "", +} +package = "example" +version = "1.0-1" +test = { + type = "command", + script = {"./unit.lua"}, +} +-------------------------------------------------------------------------------- + +RUN: luarocks test +EXIT: 1 +STDERR: +-------------------------------------------------------------------------------- +'script' expects a string +-------------------------------------------------------------------------------- |
