|
|
@@ -31,6 +31,7 @@ import org.junit.Before; |
|
|
|
import org.junit.Rule; |
|
|
|
import org.junit.rules.TestRule; |
|
|
|
import org.junit.rules.TestWatcher; |
|
|
|
import org.junit.runner.Description; |
|
|
|
import org.openqa.selenium.OutputType; |
|
|
|
import org.openqa.selenium.TakesScreenshot; |
|
|
|
import org.openqa.selenium.remote.DesiredCapabilities; |
|
|
@@ -65,7 +66,16 @@ public abstract class ScreenshotTB3Test extends AbstractTB3Test { |
|
|
|
} |
|
|
|
|
|
|
|
screenshotBaseName = className + "-" + testMethod; |
|
|
|
}; |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
protected void failed(Throwable e, Description description) { |
|
|
|
|
|
|
|
// Notify Teamcity of failed test |
|
|
|
System.out.print("##teamcity[publishArtifacts '"); |
|
|
|
System.out.println(getScreenshotErrorDirectory() + "/" |
|
|
|
+ getScreenshotBaseName() + "* => screenshot-errors']"); |
|
|
|
} |
|
|
|
}; |
|
|
|
|
|
|
|
/** |