Added test cases for cmd, which and asyncExec

This commit is contained in:
Napalys Klicius
2025-04-30 13:33:31 +02:00
parent e5d296180b
commit f6fae7ad60
2 changed files with 8 additions and 0 deletions

View File

@@ -56,6 +56,7 @@ test_FileSystemAccess
| tst.js:60:1:60:41 | shelljs ... cement) |
| tst.js:61:1:61:17 | shelljs.cat(file) |
test_MissingFileSystemAccess
| tst.js:65:15:65:18 | file |
test_SystemCommandExecution
| tst.js:14:1:14:27 | shelljs ... ts, cb) |
| tst.js:60:1:60:51 | shelljs ... ec(cmd) |

View File

@@ -59,3 +59,10 @@ shelljs.uniq(opts, file1, file2);
shelljs.cat(file).sed(regex, replacement).exec(cmd);
shelljs.cat(file).exec(cmd);
shelljs.cmd(cmd, arg1, arg2, options);
shelljs.cmd(cmd);
shelljs.which(file);
const shelljssync = require("async-shelljs");
shelljssync.asyncExec(cmd, opts, cb);