Skip to content

Test name duplicated in the report #831

Description

@iNikem

I have the following simple JUnit test:

  @RepeatedTest(value = 2, name = RepeatedTest.LONG_DISPLAY_NAME)
  @DisplayName("Long name")
  public void repeatLong() {
    Assertions.assertTrue(true);
  }

  @RepeatedTest(value = 2, name = RepeatedTest.SHORT_DISPLAY_NAME)
  @DisplayName("Short name")
  public void repeatShort() {
    Assertions.assertTrue(true);
  }

Here how does the Allure report for it looks like:
Screenshot 2022-10-20 at 10 38 00

As you can see, name of the repeatLong test method has duplicated portion in it. I expect the name to be "Long name :: repetition 1 of 2" instead of "Long name Long name :: repetition 1 of 2".

For reference, this is how test names look in IntelliJ IDEA:
Screenshot 2022-10-20 at 10 40 17

and in gradle html report:
Screenshot 2022-10-20 at 10 40 48

Desktop (please complete the following information):

  • OS: macOS 12.5.1
  • Browser: Safari 15.6.1

JUnit version 5.8.1, Gradle Allure plugin 2.11.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions