diff options
| author | Hisham Muhammad <hisham@gobolinux.org> | 2018-04-30 15:56:03 -0300 |
|---|---|---|
| committer | Hisham Muhammad <hisham@gobolinux.org> | 2018-05-07 19:27:37 -0300 |
| commit | 3c3e48f5b3f081e3bf446c6a764b90a60293ed8e (patch) | |
| tree | 567d5b2fb9fca9a5f8e83b531114c87e4175740d /src | |
| parent | 6c6b39a41a446b05bb2263e274f916946f0787f4 (diff) | |
| download | luarocks-3c3e48f5b3f081e3bf446c6a764b90a60293ed8e.tar.gz luarocks-3c3e48f5b3f081e3bf446c6a764b90a60293ed8e.tar.bz2 luarocks-3c3e48f5b3f081e3bf446c6a764b90a60293ed8e.zip | |
test.busted: add explicit fallback for finding Busted on Windows
Diffstat (limited to 'src')
| -rw-r--r-- | src/luarocks/test/busted.lua | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/luarocks/test/busted.lua b/src/luarocks/test/busted.lua index a3aaed08..c27c449c 100644 --- a/src/luarocks/test/busted.lua +++ b/src/luarocks/test/busted.lua | |||
| @@ -31,7 +31,11 @@ function busted.run_tests(test, args) | |||
| 31 | busted_exe = test.busted_executable | 31 | busted_exe = test.busted_executable |
| 32 | else | 32 | else |
| 33 | busted_exe = dir.path(path.root_dir(where), "bin", "busted") | 33 | busted_exe = dir.path(path.root_dir(where), "bin", "busted") |
| 34 | if not fs.exists(busted_exe) then | 34 | |
| 35 | -- Windows fallback | ||
| 36 | local busted_bat = dir.path(path.root_dir(where), "bin", "busted.bat") | ||
| 37 | |||
| 38 | if not fs.exists(busted_exe) and not fs.exists(busted_bat) then | ||
| 35 | return nil, "'busted' executable failed to be installed" | 39 | return nil, "'busted' executable failed to be installed" |
| 36 | end | 40 | end |
| 37 | end | 41 | end |
