net.thucydides.core
Class Thucydides

Package class diagram package Thucydides
java.lang.Object
  extended by net.thucydides.core.Thucydides

public class Thucydides
extends Object

A utility class that provides services to initialize web testing and reporting-related fields in arbitrary objects. It is designed to help integrate Thucydides into other testing tools such as Cucumber.


Constructor Summary
Thucydides()
           
 
Method Summary
static void done()
          Indicate that the test run using this object is finished, and reports can be generated.
static SessionMap getCurrentSession()
           
static String getCurrentSessionID()
           
static String getDefaultProjectKey()
          The current working directory name is used as a default project key if no other key is provided.
protected static org.openqa.selenium.WebDriver getDriver()
           
static org.openqa.selenium.firefox.FirefoxProfile getFirefoxProfile()
           
protected static Pages getPages()
           
static StepFactory getStepFactory()
           
static StepListener getStepListener()
           
static void ignoredStep(String reason)
           
static void initialize(Object testCase)
          Initialize Thucydides-related fields in the specified object.
static void initializeTestSession()
           
protected static void injectAnnotatedPagesObjectInto(Object testCase)
          Instantiates the @ManagedPages-annotated Pages instance using current WebDriver.
protected static void injectDriverInto(Object testCase)
          Instantiate the @Managed-annotated WebDriver instance with current WebDriver.
static void injectScenarioStepsInto(Object testCase)
          Instantiates the @ManagedPages-annotated Pages instance using current WebDriver.
static void pendingStep(String reason)
           
protected static void stopUsingMockDriver()
           
static void takeScreenshot()
           
static void useFirefoxProfile(org.openqa.selenium.firefox.FirefoxProfile profile)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Thucydides

public Thucydides()
Method Detail

initialize

public static void initialize(Object testCase)
Initialize Thucydides-related fields in the specified object. This includes managed WebDriver instances,


injectDriverInto

protected static void injectDriverInto(Object testCase)
Instantiate the @Managed-annotated WebDriver instance with current WebDriver.


injectScenarioStepsInto

public static void injectScenarioStepsInto(Object testCase)
Instantiates the @ManagedPages-annotated Pages instance using current WebDriver.


injectAnnotatedPagesObjectInto

protected static void injectAnnotatedPagesObjectInto(Object testCase)
Instantiates the @ManagedPages-annotated Pages instance using current WebDriver.


done

public static void done()
Indicate that the test run using this object is finished, and reports can be generated.


getCurrentSessionID

public static String getCurrentSessionID()

getDriver

protected static org.openqa.selenium.WebDriver getDriver()

getPages

protected static Pages getPages()

stopUsingMockDriver

protected static void stopUsingMockDriver()

getStepFactory

public static StepFactory getStepFactory()

getStepListener

public static StepListener getStepListener()

initializeTestSession

public static void initializeTestSession()

getCurrentSession

public static SessionMap getCurrentSession()

pendingStep

public static void pendingStep(String reason)

ignoredStep

public static void ignoredStep(String reason)

takeScreenshot

public static void takeScreenshot()

getDefaultProjectKey

public static String getDefaultProjectKey()
The current working directory name is used as a default project key if no other key is provided.


useFirefoxProfile

public static void useFirefoxProfile(org.openqa.selenium.firefox.FirefoxProfile profile)

getFirefoxProfile

public static org.openqa.selenium.firefox.FirefoxProfile getFirefoxProfile()


Copyright © 2011-2013 Wakaleo Consulting. All Rights Reserved.