Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tags are missing in serenity report 4.0.15 #3300

Closed
aybartsch opened this issue Oct 23, 2023 · 6 comments
Closed

Tags are missing in serenity report 4.0.15 #3300

aybartsch opened this issue Oct 23, 2023 · 6 comments

Comments

@aybartsch
Copy link

What happened?

I have migrated an old serenity project 2.5.8 to the latest release 4.0.15 plus moving test cases from jUnit 4 to 5. The tests are running but the tags defined by "WithTags/WithTag" are missing in the serenity report.

What did you expect to happen?

The tags defined by "WithTags/WithTag" annotations should be present in the serenity report.

Serenity BDD version

4.0.15

JDK version

11.0.21

Execution environment

OS: macOS Monterey 12.7
Browser: Chrome 118.0.5993.96

How to reproduce the bug.

  1. Run the below test case
@ExtendWith(SerenityJUnit5Extension.class)
@WithTags({@WithTag(type = "Test", name = "SomeTest"), @WithTag(type = "Application", name = "SomeApplication")})
public class SmokeTest {

@Test
public void runSmokeTest() {
      // Some test here...
   }
}
  1. Aggregate the report
  2. Open the report and verify tags

Workaround: Using jUnit 5 annotations

@Tags({@Tag("Test:SomeTest"), @Tag("Application:SomeApplication")})

How can we make it happen?

Add it to the Serenity BDD backlog and wait for a volunteer to pick it up

@wakaleo
Copy link
Member

wakaleo commented Oct 23, 2023

Are you using the JUnit 5 tags?

@aybartsch
Copy link
Author

I'm currently using the jUnit 5 tags as a workaround but would be prefer to use serenity tags instead.

@wakaleo
Copy link
Member

wakaleo commented Oct 23, 2023

The serenity tags are only for JUnit 4 - in JUnit 5 only native JUnit 5 tags are supported

@aybartsch
Copy link
Author

aybartsch commented Oct 23, 2023

Okay. Should the annotations not be excluded from serenity-model-4.0.15.jar or marked as deprecated?

@wakaleo
Copy link
Member

wakaleo commented Oct 23, 2023

No, because they are still relevant for JUnit 4 tests.

@aybartsch
Copy link
Author

Thanks, John!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants