示例#1
0
    public async void VerifyScenario(DotNetTemplate template)
    {
        await InitializeOmniSharp();

        string templateName     = template.GetName();
        string projectName      = $"{nameof(OmniSharpTests)}_{templateName}";
        string projectDirectory = DotNetHelper.ExecuteNew(templateName, projectName);

        (Process Process, string StdOut, string StdErr)executeResult = ExecuteHelper.ExecuteProcess(
            Path.Combine(OmniSharpDirectory, "run"),
            $"-s {projectDirectory}",
            OutputHelper,
            logOutput: true,
            millisecondTimeout: 5000,
            configure: (process) => DotNetHelper.ConfigureProcess(process, projectDirectory, setPath: true));

        Assert.NotEqual(0, executeResult.Process.ExitCode);
        Assert.DoesNotContain("ERROR", executeResult.StdOut);
        Assert.DoesNotContain("ERROR", executeResult.StdErr);
    }