private void AssertSuccessByExecutionForSingleTest()
        {
            Assert.IsNotNull(BodyCodeBlock);

            methodEmitter.ParseTree(BodyCodeBlock);
            methodEmitter.SetAsEntryPoint();
            Assert.IsTrue(assemblyEmitter.Save());

            PEVerifyRunner.Run(assemblyEmitter.OutputPath);
            var stdout = ManagedCodeRunner.CreateProcessAndRun(assemblyEmitter.OutputPath, new string[0] {
            });

            Assert.AreEqual(ExpectedOutput.Trim(), stdout.Trim());
        }
Beispiel #2
0
        private void Run(string path, IntegrationTestInfo testInfo)
        {
            var stdout = ManagedCodeRunner.CreateProcessAndRun(path, testInfo.Arguments, testInfo.StdIn, kRunTimeOut);

            Assert.AreEqual(testInfo.StdOut.Trim(), stdout.Trim());
        }
Beispiel #3
0
        private void Build(IEnumerable <string> sourceFiles, IEnumerable <string> references, string outPath)
        {
            var args = sourceFiles.Union(references).Union(new[] { "/console", "/out:" + outPath }).ToArray();

            ManagedCodeRunner.CreateProcessAndRun("LaborasLangCompiler.exe", args, null, kBuildTimeOut);
        }