Search in sources :

Example 1 with Hub

use of com.coveros.selenified.utilities.Hub in project selenified by Coveros.

the class HubTest method defaultGetHubOverrideEmptyTest.

@Test(expectedExceptions = InvalidHubException.class)
public void defaultGetHubOverrideEmptyTest() throws IOException {
    System.setProperty(HUB, "");
    createPropertiesFile(HUB + "=somehub");
    new Hub().getHubURL();
}
Also used : Hub(com.coveros.selenified.utilities.Hub) Test(org.testng.annotations.Test)

Example 2 with Hub

use of com.coveros.selenified.utilities.Hub in project selenified by Coveros.

the class HubTest method defaultGetHubFileBadTest.

@Test(expectedExceptions = InvalidHubException.class)
public void defaultGetHubFileBadTest() throws IOException {
    createPropertiesFile(HUB + "=somehub");
    new Hub().getHubURL();
}
Also used : Hub(com.coveros.selenified.utilities.Hub) Test(org.testng.annotations.Test)

Example 3 with Hub

use of com.coveros.selenified.utilities.Hub in project selenified by Coveros.

the class HubTest method defaultGetHubOverrideBadTest.

@Test(expectedExceptions = InvalidHubException.class)
public void defaultGetHubOverrideBadTest() throws IOException {
    System.setProperty(HUB, "somehub");
    createPropertiesFile(HUB + "=");
    new Hub().getHubURL();
}
Also used : Hub(com.coveros.selenified.utilities.Hub) Test(org.testng.annotations.Test)

Example 4 with Hub

use of com.coveros.selenified.utilities.Hub in project selenified by Coveros.

the class HubTest method getKeyOnlyKeyTest.

@Test(expectedExceptions = InvalidHubException.class)
public void getKeyOnlyKeyTest() throws MalformedURLException {
    System.setProperty(HUB, "https://sauceaccesskey@ondemand.saucelabs.com:443");
    new Hub().getPassword();
}
Also used : Hub(com.coveros.selenified.utilities.Hub) Test(org.testng.annotations.Test)

Example 5 with Hub

use of com.coveros.selenified.utilities.Hub in project selenified by Coveros.

the class HubTest method getUserNoUserTest.

@Test
public void getUserNoUserTest() throws MalformedURLException {
    System.setProperty(HUB, "https://ondemand.saucelabs.com:443");
    assertEquals(new Hub().getHubURL(), new URL("https://ondemand.saucelabs.com:443/wd/hub"));
    assertNull(new Hub().getUsername());
    assertNull(new Hub().getPassword());
}
Also used : Hub(com.coveros.selenified.utilities.Hub) URL(java.net.URL) Test(org.testng.annotations.Test)

Aggregations

Hub (com.coveros.selenified.utilities.Hub)24 Test (org.testng.annotations.Test)24 Call (com.coveros.selenified.services.Call)10 Response (com.coveros.selenified.services.Response)10 SessionId (org.openqa.selenium.remote.SessionId)10 HashMap (java.util.HashMap)6 URL (java.net.URL)4 ArrayList (java.util.ArrayList)4 JsonArray (com.google.gson.JsonArray)1