Skip to content

JUnit 5 ParameterizedTest results not properly flagged for complex arguments #1603

Open
@JGitHub01

Description

@JGitHub01

When parameters for a ParameterizedTest is provided by MethodSource that return stream of Arguments of non primitive type e.g. double[], the test results are not flagged with a green check for success test. Instead, it shows a grey circle without a dropdown that show test result for each test case.

image

Example Code:

public class ExampleTest {
  @ParameterizedTest
  @MethodSource("parameters")
  void shouldDoParameterizedTest(double[] s) {
    assertNotNull(s[0]);
    assertNotNull(s[1]);
  }

  static Stream<Arguments> parameters() {
    return Stream.of(Arguments.of(new double[] {
        0.01d, 0.05d
    }), Arguments.of(new double[] {
        0.02d, 0.04d
    }));
  }
}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions