Closed aaschmid closed 11 years ago
Findings so far:
toString()
method and therefore using Object.toString()
Integer.toHexString(super.hashCode());
as toString()
method, whereby hashCode()
must use Object.hashCode()
(using Eclipse generated hashCode()
function works normally)For a @Parameterized
test using an equal "data provider" it is working because the JUnit Eclipse plugin just shows indices to distingish between the different test data such that the test will not be show as unrooted. This would also work for DataProviderRunner
but it not really what I desired ...
Having a more precise look in a silent minute made clear that I missed the forest for the trees ...
As the above screenshot shows the data simply changed because com.tngtech.java.junit.dataprovider.DataProviderRunner.computeTestMethods()
was called multiple times :(
Using Eclipse JUnit plugin some test cases appear under the category "Unrooted tests" instead of the expected class name, see
See the reproducer in
com.tngtech.test.java.junit.dataprovider.DataProviderEclipseJUnitPluginUnrootedReproducerAcceptanceTest
for more information.