diff --git a/src/.editorconfig b/.editorconfig similarity index 100% rename from src/.editorconfig rename to .editorconfig diff --git a/src/YesNt.Interpreter.Tests/SystemStatementsTests.cs b/src/YesNt.Interpreter.Tests/SystemStatementsTests.cs index d8f4138..1c2dd15 100644 --- a/src/YesNt.Interpreter.Tests/SystemStatementsTests.cs +++ b/src/YesNt.Interpreter.Tests/SystemStatementsTests.cs @@ -12,7 +12,7 @@ public class SystemStatementsTests { List lines = [ - "exec cmd with /c,echo yesnt", + "exec whoami", "var exitCode = %out", "${exitCode}" ]; @@ -20,14 +20,26 @@ public class SystemStatementsTests YesNtAssert.IsLastLineEqual(lines, "0"); } + [TestMethod] + public void ExecWithArgsRunsProcessTestWithArgument() + { + List lines = + [ + "exec whoami with /?", + "var exitCode = %out", + "var dummy = 0", + "${dummy}" + ]; + + YesNtAssert.IsLastLineEqual(lines, "0"); + } + [TestMethod] public void ExecWithInStackArgsRunsProcessTest() { List lines = [ - "push_in /c", - "push_in echo yesnt", - "exec cmd", + "exec whoami", "var exitCode = %out", "${exitCode}" ];