Esempio n. 1
0
 public static string InProcessThreadException(IISDeploymentResult deploymentResult, string reason)
 {
     return($"Application '/LM/W3SVC/1/ROOT' with physical root '{EscapedContentRoot(deploymentResult)}' hit unexpected managed exception{reason}");
 }
Esempio n. 2
0
 public static string ShutdownFileChange(IISDeploymentResult deploymentResult)
 {
     return($"Application '{EscapedContentRoot(deploymentResult)}' was recycled after detecting file change in application directory.");
 }
Esempio n. 3
0
 public static string InProcessFailedToStop(IISDeploymentResult deploymentResult, string reason)
 {
     return("Failed to gracefully shutdown application 'MACHINE/WEBROOT/APPHOST/.*?'.");
 }
Esempio n. 4
0
 private Task AssertSiteFailsToStartWithInProcessStaticContent(IISDeploymentResult deploymentResult)
 {
     return(AssertSiteFailsToStartWithInProcessStaticContent(deploymentResult, "500.0"));
 }
Esempio n. 5
0
 public static string InProcessFailedToStart(IISDeploymentResult deploymentResult, string reason)
 {
     return($"Application '/LM/W3SVC/1/ROOT' with physical root '{EscapedContentRoot(deploymentResult)}' failed to load clr and managed application. {reason}");
 }
Esempio n. 6
0
 public static string InProcessHostfxrUnableToLoad(IISDeploymentResult deploymentResult)
 {
     return($"Unable to load '(.*)'. This might be caused by a bitness mismatch between IIS application pool and published application.");
 }
Esempio n. 7
0
 private void AssertFrebLogs(IISDeploymentResult result, params FrebLogItem[] expectedFrebEvents)
 {
     AssertFrebLogs(result, (IEnumerable <FrebLogItem>)expectedFrebEvents);
 }
Esempio n. 8
0
 public static string InProcessFailedToFindRequestHandler(IISDeploymentResult deploymentResult)
 {
     return("Could not find the assembly '(.*)' referenced for the in-process application. Please confirm the Microsoft.AspNetCore.Server.IIS package is referenced in your application.");
 }
Esempio n. 9
0
        private async Task AssertAppOffline(IISDeploymentResult deploymentResult, string expectedResponse = "The app is offline.")
        {
            var response = await deploymentResult.HttpClient.RetryRequestAsync("HelloWorld", r => r.StatusCode == HttpStatusCode.ServiceUnavailable);

            Assert.Equal(expectedResponse, await response.Content.ReadAsStringAsync());
        }
Esempio n. 10
0
 public static string OutOfProcessFailedToStart(IISDeploymentResult deploymentResult)
 {
     return($"Application '/LM/W3SVC/1/ROOT' with physical root '{EscapedContentRoot(deploymentResult)}' failed to start process with " +
            $"commandline '(.*)' with multiple retries. " +
            $"The last try of listening port is '(.*)'. See previous warnings for details.");
 }
Esempio n. 11
0
 public static string InProcessFailedToFindNativeDependencies(IISDeploymentResult deploymentResult)
 {
     return("Invoking hostfxr to find the inprocess request handler failed without finding any native dependencies. " +
            "This most likely means the app is misconfigured, please check the versions of Microsoft.NetCore.App and Microsoft.AspNetCore.App that " +
            "are targeted by the application and are installed on the machine.");
 }
Esempio n. 12
0
 public static string ConfigurationLoadError(IISDeploymentResult deploymentResult, string reason)
 {
     return($"Could not load configuration. Exception message: {reason}");
 }
Esempio n. 13
0
 public static string InProcessThreadExitStdOut(IISDeploymentResult deploymentResult, string code, string output)
 {
     return($"Application '/LM/W3SVC/1/ROOT' with physical root '{EscapedContentRoot(deploymentResult)}' hit unexpected managed background thread exit, exit code = '{code}'. Last 4KB characters of captured stdout and stderr logs:\r\n{output}");
 }
Esempio n. 14
0
 public static string InProcessThreadExit(IISDeploymentResult deploymentResult, string code)
 {
     return($"Application '/LM/W3SVC/1/ROOT' with physical root '{EscapedContentRoot(deploymentResult)}' hit unexpected managed background thread exit, exit code = '{code}'.");
 }
Esempio n. 15
0
 public static string FailedToStartApplication(IISDeploymentResult deploymentResult, string code)
 {
     return($"Failed to start application '/LM/W3SVC/1/ROOT', ErrorCode '{code}'.");
 }
Esempio n. 16
0
 public string GetLogFileContent(IISDeploymentResult deploymentResult)
 {
     return(Helpers.ReadAllTextFromFile(Helpers.GetExpectedLogName(deploymentResult, _logFolderPath), Logger));
 }
Esempio n. 17
0
 public static string InProcessHostfxrInvalid(IISDeploymentResult deploymentResult)
 {
     return($"Hostfxr version used does not support 'hostfxr_get_native_search_directories', update the version of hostfxr to a higher version. Path to hostfxr: '(.*)'.");
 }
Esempio n. 18
0
 private string GetANCMRequestHandlerPath(IISDeploymentResult deploymentResult, string version)
 {
     return(Path.Combine(deploymentResult.ContentRoot,
                         deploymentResult.DeploymentParameters.RuntimeArchitecture.ToString(),
                         version));
 }
Esempio n. 19
0
 public static string CouldNotStartStdoutFileRedirection(string file, IISDeploymentResult deploymentResult)
 {
     return
         ($"Could not start stdout file redirection to '{Regex.Escape(file)}' with application base '{EscapedContentRoot(deploymentResult)}'.");
 }
Esempio n. 20
0
 private static string AncmVersionToMatch(IISDeploymentResult deploymentResult)
 {
     return("IIS " +
            (deploymentResult.DeploymentParameters.ServerType == ServerType.IISExpress ? "Express " : "") +
            "AspNetCore Module V2");
 }
Esempio n. 21
0
 public static void AllowNoLogs(this IISDeploymentResult deploymentResult)
 {
     File.AppendAllText(
         Path.Combine(deploymentResult.DeploymentParameters.PublishedApplicationRootPath, "aspnetcore-debug.log"),
         "Running test allowed log file to be empty." + Environment.NewLine);
 }
Esempio n. 22
0
 public static string OutOfProcessStarted(IISDeploymentResult deploymentResult)
 {
     return($"Application '/LM/W3SVC/1/ROOT' started process '\\d+' successfully and process '\\d+' is listening on port '\\d+'.");
 }
Esempio n. 23
0
 private Task AssertSiteFailsToStartWithInProcessStaticContent(IISDeploymentResult deploymentResult)
 {
     return(AssertSiteFailsToStartWithInProcessStaticContent(deploymentResult, "HTTP Error 500.0 - ANCM In-Process Handler Load Failure"));
 }
Esempio n. 24
0
 public static string InProcessStarted(IISDeploymentResult deploymentResult)
 {
     return($"Application '{EscapedContentRoot(deploymentResult)}' started the coreclr in-process successfully");
 }