/** * Instantiate the @Managed-annotated WebDriver instance with current WebDriver. */ protected static void injectDriverInto(final Object testCase) { TestCaseAnnotations.forTestCase(testCase).injectDriver(getDriver()); }
private boolean useUniqueBrowserSessionForScenarios() { return TestCaseAnnotations.isUniqueSession(testSuite); }
public static TestCaseAnnotations forTestCase(final Object testCase) { return new TestCaseAnnotations(testCase); }
public boolean isAWebTest() { return TestCaseAnnotations.isASerenityTestCase(testSuite) && TestCaseAnnotations.isWebTest(testSuite); } }
/** * Instantiate the @Managed-annotated WebDriver instance with current WebDriver. */ protected static void injectDriverInto(final Object testCase) { TestCaseAnnotations.forTestCase(testCase).injectDrivers(getDriver(), getWebdriverManager()); }
public void injectDrivers(final WebDriver defaultDriver, final WebdriverManager webdriverManager) { List<ManagedWebDriverAnnotatedField> webDriverFields = findAnnotatedFields(testCase.getClass()); int driverCount = 1; String suffix = ""; for(ManagedWebDriverAnnotatedField webDriverField : webDriverFields) { String driverRootName = isNotEmpty(webDriverField.getDriver()) ? webDriverField.getDriver() : configuredDriverType(); String driverName = driverRootName + suffix; String driverOptions = webDriverField.getOptions(); WebDriver driver = (isEmpty(driverName)) ? defaultDriver : requestedDriverFrom(webdriverManager, webDriverField.getName(), driverName, driverOptions); webDriverField.setValue(testCase, driver); suffix = nextSuffix(driverCount++); } }
public boolean isAWebTest() { return TestCaseAnnotations.isWebTest(getTestClass().getJavaClass()); } }
public void injectDrivers(final WebdriverManager webdriverManager) { injectDrivers(ThucydidesWebDriverSupport.getDriver(),webdriverManager); }
/** * Instantiate the @Managed-annotated WebDriver instance with current WebDriver. * @param testCase any object (testcase or other) containing injectable Serenity components */ protected static void injectDriverInto(final Object testCase) { TestCaseAnnotations.forTestCase(testCase).injectDrivers(ThucydidesWebDriverSupport.getDriver(), ThucydidesWebDriverSupport.getWebdriverManager()); }
/** * Instantiate the @Managed-annotated WebDriver instance with current WebDriver. */ protected static void injectDriverInto(final Object testCase) { TestCaseAnnotations.forTestCase(testCase).injectDriver(getDriver()); }
public boolean isUniqueSession() { return isUniqueSession(testCase.getClass()); }
public static TestCaseAnnotations forTestCase(final Object testCase) { return new TestCaseAnnotations(testCase); }
/** * Instantiate the @Managed-annotated WebDriver instance with current WebDriver. */ protected static void injectDriverInto(final Object testCase) { TestCaseAnnotations.forTestCase(testCase).injectDriver(getDriver()); }
public boolean isUniqueSession() { return isUniqueSession(testCase.getClass()); }
public static TestCaseAnnotations forTestCase(final Object testCase) { return new TestCaseAnnotations(testCase); }
/** * Instantiate the @Managed-annotated WebDriver instance with current WebDriver. */ protected void injectDriverInto(final Object testCase, final FrameworkMethod method) { TestCaseAnnotations.forTestCase(testCase).injectDriver(driverFor(method)); }
public boolean isUniqueSession() { return isUniqueSession(testCase.getClass()); }
/** * Instantiate the @Managed-annotated WebDriver instance with current WebDriver. * @param testCase any object (testcase or other) containing injectable Serenity components */ protected static void injectDriverInto(final Object testCase) { TestCaseAnnotations.forTestCase(testCase).injectDriver(getDriver()); }
protected boolean isUniqueSession() { return TestCaseAnnotations.isUniqueSession(getTestClass().getJavaClass()); }