Skip to content

Commit 7dca116

Browse files
committed
fix: resolve checkstyle issues in allure-testng-7
1 parent bd6fe09 commit 7dca116

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

allure-testng-7/src/main/java/io/qameta/allure/testng/AllureTestNg.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ public class AllureTestNg implements
115115
private static final Logger LOGGER = LoggerFactory.getLogger(AllureTestNg.class);
116116

117117
private static final String ALLURE_UUID = "ALLURE_UUID";
118+
private static final String ALLURE_FIXTURE_STARTED = "ALLURE_FIXTURE_STARTED";
118119
private static final List<Class<?>> INJECTED_TYPES = Arrays.asList(
119120
ITestContext.class, ITestResult.class, XmlTest.class, Method.class, Object[].class
120121
);
@@ -470,7 +471,7 @@ public void beforeInvocation(final IInvokedMethod method, final ITestResult test
470471
final ITestNGMethod testMethod = method.getTestMethod();
471472
final ITestContext context = testResult.getTestContext();
472473
if (isSupportedConfigurationFixture(testMethod) && testResult.getStatus() != ITestResult.SKIP) {
473-
testResult.setAttribute("ALLURE_FIXTURE_STARTED", true);
474+
testResult.setAttribute(ALLURE_FIXTURE_STARTED, true);
474475
ifSuiteFixtureStarted(context.getSuite(), testMethod);
475476
ifTestFixtureStarted(context, testMethod);
476477
ifClassFixtureStarted(testMethod);
@@ -570,8 +571,8 @@ private FixtureResult getFixtureResult(final ITestNGMethod method) {
570571
@Override
571572
public void afterInvocation(final IInvokedMethod method, final ITestResult testResult) {
572573
final ITestNGMethod testMethod = method.getTestMethod();
573-
if (isSupportedConfigurationFixture(testMethod) && testResult.getAttribute("ALLURE_FIXTURE_STARTED") != null) {
574-
testResult.removeAttribute("ALLURE_FIXTURE_STARTED");
574+
if (isSupportedConfigurationFixture(testMethod) && testResult.getAttribute(ALLURE_FIXTURE_STARTED) != null) {
575+
testResult.removeAttribute(ALLURE_FIXTURE_STARTED);
575576
final String executableUuid = currentExecutable.get();
576577
currentExecutable.remove();
577578
if (testResult.isSuccess()) {

0 commit comments

Comments
 (0)