how to run junit parameterized tests in order of parameters declared

65 views Asked by At

I am writing a junit parameterized test, and I have the following parameters for example: "A", "B", "C". Everytime I run the test, the parameter's order is always different and I want it to always run in the order I defined them.

Is there a way?

I ve searched online, but I could not find any info about it...

1

There are 1 answers

0
Saratean Timeea On

Solved it by using sort() on collection inside method that is marked with @Parameterized annotation