Ejemplo n.º 1
0
 public Home_page(ITestOutputHelper output, WebDriverContext webDriverContext) : base(output)
 {
     _client = ClientHelper.Build();
     _client.RegisterTestEndpoints();
     _driver  = webDriverContext.Driver;
     _homeUrl = $"{SeleniumConfiguration.BaseUrl}?endpoint-frequency=1000000&config-frequency=1000000";
 }
 public Swagger_page(ITestOutputHelper output, WebDriverContext webDriverContext) : base(output)
 {
     _client = ClientHelper.Build();
     _client.RegisterTestEndpoints();
     _driver     = webDriverContext.Driver;
     _swaggerUrl = $"{SeleniumConfiguration.BaseUrl}/swagger/ui/index";
 }
 public Home_page(ITestOutputHelper output) : base(output)
 {
     _client = ClientHelper.Build();
     _client.RegisterTestEndpoints();
     _driver = SeleniumConfiguration.GetWebDriver();
     _driver.RetryTimeout(Timeouts.Default);
     _homeUrl = $"{SeleniumConfiguration.BaseUrl}?endpoint-frequency=1000000&config-frequency=1000000";
 }
 public Dashboard_page(ITestOutputHelper output, WebDriverContext webDriverContext) : base(output)
 {
     _dashboardUrl = $"{SeleniumConfiguration.BaseUrl}dashboard?endpoint-frequency=1000000&config-frequency=1000000";
     _groupFilter  = $"{SeleniumHelper.TestGroups[0].Replace("group", "*")}";
     _client       = ClientHelper.Build();
     _client.RegisterTestEndpoints();
     _driver = webDriverContext.Driver;
 }
 public Dashboard_page(ITestOutputHelper output) : base(output)
 {
     _dashboardUrl = $"{SeleniumConfiguration.BaseUrl}dashboard?endpoint-frequency=1000000&config-frequency=1000000";
     _groupFilter  = $"{SeleniumHelper.TestGroups[0].Replace("group", "*")}";
     _client       = ClientHelper.Build();
     _client.RegisterTestEndpoints();
     _driver = SeleniumConfiguration.GetWebDriver();
     _driver.RetryTimeout(Timeouts.Default);
 }
Ejemplo n.º 6
0
        public Details_page(ITestOutputHelper output, WebDriverContext webDriverContext) : base(output)
        {
            _client = ClientHelper.Build();
            _client.RegisterTestEndpoints();
            _driver = webDriverContext.Driver;

            _endpointLinksOfTagRowsOnHomePage  = $"{_rowsWithTags}//td[2]//a";
            _endpointGroupsOfTagRowsOnHomePage = $"{_rowsWithTags}//td[1]";
            _endpointTagsOnHomePage            = $"{_rowsWithTags}//td[6]//span";
        }
        public Details_page(ITestOutputHelper output) : base(output)
        {
            _client = ClientHelper.Build();
            _client.RegisterTestEndpoints();
            _driver = SeleniumConfiguration.GetWebDriver();
            _driver.RetryTimeout(Timeouts.Default);

            _endpointLinksOfTagRowsOnHomePage  = $"{_rowsWithTags}//td[2]//a";
            _endpointGroupsOfTagRowsOnHomePage = $"{_rowsWithTags}//td[1]";
            _endpointTagsOnHomePage            = $"{_rowsWithTags}//td[6]//span";
        }
Ejemplo n.º 8
0
        private static void EnsureProcessesAlive()
        {
            Wait.Until(
                TimeSpan.FromSeconds(30),
                () => ClientHelper.Build().Get(new RestRequest("/api/monitors")),
                resp => resp.StatusCode == HttpStatusCode.OK && JsonConvert.DeserializeObject <string[]>(resp.Content).Any(type => !type.Equals("push", StringComparison.OrdinalIgnoreCase)),
                "Services did not initialized properly");

            if (_api.Item1.IsAlive && _monitor.Item1.IsAlive)
            {
                return;
            }

            Terminate();
            throw new InvalidOperationException("HealthMonitor processes failed to start");
        }
        private static void EnsureProcessesAlive()
        {
            Wait.Until(
                Timeouts.Default,
                () => ClientHelper.Build().Get(new RestRequest("/api/monitors")),
                resp =>
            {
                if (resp.StatusCode != HttpStatusCode.OK)
                {
                    return(false);
                }
                var monitorTypes = JsonConvert.DeserializeObject <string[]>(resp.Content);
                return(monitorTypes.Contains("nsb6.rabbitmq") && monitorTypes.Contains("nsb5.rabbitmq"));
            },
                "Services did not initialized properly");

            if (_api.Item1.IsAlive && _monitor.Item1.IsAlive && _nsb6Monitor.Item1.IsAlive)
            {
                return;
            }

            Terminate();
            throw new InvalidOperationException("HealthMonitor processes failed to start");
        }
 private void Given_a_monitor_api_client()
 {
     _client = ClientHelper.Build();
 }