Class XrayListener

java.lang.Object
app.getxray.xray.testng.listeners.XrayListener
All Implemented Interfaces:
org.testng.IInvokedMethodListener, org.testng.ITestListener, org.testng.ITestNGListener

public class XrayListener extends Object implements org.testng.IInvokedMethodListener, org.testng.ITestListener
The listener interface for receiving events related to execution of tests, and process Xray related annotations. The listener can be automatically invoked when TestNG tests are run by using ServiceLoader mechanism. You can also add this listener to a TestNG Test class by adding @Listeners({app.getxray.testng.XrayListener.class}) before the test class
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    afterInvocation(org.testng.IInvokedMethod method, org.testng.ITestResult testResult)
     
    void
    beforeInvocation(org.testng.IInvokedMethod method, org.testng.ITestResult testResult)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.testng.IInvokedMethodListener

    afterInvocation, beforeInvocation

    Methods inherited from interface org.testng.ITestListener

    onFinish, onStart, onTestFailedButWithinSuccessPercentage, onTestFailedWithTimeout, onTestFailure, onTestSkipped, onTestStart, onTestSuccess

    Methods inherited from interface org.testng.ITestNGListener

    isEnabled
  • Constructor Details

    • XrayListener

      public XrayListener()
  • Method Details

    • beforeInvocation

      public void beforeInvocation(org.testng.IInvokedMethod method, org.testng.ITestResult testResult)
      Specified by:
      beforeInvocation in interface org.testng.IInvokedMethodListener
    • afterInvocation

      public void afterInvocation(org.testng.IInvokedMethod method, org.testng.ITestResult testResult)
      Specified by:
      afterInvocation in interface org.testng.IInvokedMethodListener