Ejemplo n.º 1
0
        public void NewRelicAgentEnabledFalse_ProfilerNotLoaded()
        {
            var installTestApp = new TestApplication(application: Applications.DotNet_Functional_InstallTestApp);

            TServer.IISCommand("Stop");
            TServer.PurgeAgentLogs();

            TServer.ModifyOrCreateXmlAttribute("//x:configuration", "agentEnabled", "false");
            TServer.ModInstallAppWebConfigXML(agentEnabled: true);

            // Start the service, let run for 5 seconds
            TServer.IISCommand("Start");
            installTestApp.SimpleTestRequest(resource: "service/start");
            Thread.Sleep(5000);

            // Verify the 'NewRelic.Profiler' is NOT loaded
            Assert.IsFalse(Common.FileLoadedInProcess(TServer.MgmtScope, "NewRelic.Profiler", "w3wp.exe"));
            TServer.IISCommand("Stop");
        }
Ejemplo n.º 2
0
        public void AgentEnabledTrue_ILLoaded()
        {
            var installTestApp = new TestApplication(application: Applications.DotNet_Functional_InstallTestApp);

            TServer.IISCommand("Stop");
            TServer.PurgeAgentLogs();

            TServer.ModifyOrCreateXmlAttribute("//x:configuration", "agentEnabled", "true");
            TServer.ModInstallAppWebConfigXML(agentEnabled: true);

            // Start the service, wait for logging to occur
            TServer.IISCommand("Start");
            installTestApp.SimpleTestRequest(resource: "service/start");
            installTestApp.WaitForLog(TestApplication.LogEntry.fullyConnected);

            // Verify the 'NewRelic.Profiler' is loaded, stop the service
            Assert.IsTrue(Common.FileLoadedInProcess(TServer.MgmtScope, "NewRelic.Profiler", "w3wp.exe"));
            TServer.IISCommand("Stop");
        }
Ejemplo n.º 3
0
        public void AgentEnabledFalse_NewRelicCoreNotLoaded()
        {
            var installTestApp = new TestApplication(application: Applications.DotNet_Functional_InstallTestApp);

            TServer.IISCommand("Stop");
            TServer.PurgeAgentLogs();

            TServer.ModifyOrCreateXmlAttribute("//x:configuration", "agentEnabled", "true");
            TServer.ModInstallAppWebConfigXML(agentEnabled: false);

            // Start the service, let run for 5 seconds
            TServer.IISCommand("Start");
            installTestApp.SimpleTestRequest(resource: "service/start");
            Thread.Sleep(5000);

            // Verify the 'NewRelic.Core' is NOT loaded
            //Web apps load and keep the profiler, agent.core, and extensions in the scenario.  Console apps drop everything.
            Assert.IsFalse(Common.FileLoadedInProcess(TServer.MgmtScope, "NewRelic.Core", "w3wp.exe"));
            TServer.IISCommand("Stop");
        }