Skip to content

Conversation

@pholser
Copy link
Contributor

@pholser pholser commented Jul 9, 2011

Attempt 2: Setting up for resolving issue 64, Theories honoring generic type parameters. This commit comprises only those changes required in the core of JUnit -- basically adding a validator that the Theories runner can call to reject theories with generic type variables (that are hard to resolve), and deprecating FrameworkMethod#producesType, which only the Theories runner uses, and which will be supplanted by an equivalent method on ParameterSignature. Other required changes will be added to the Theories experiment once it migrates over to junit.contrib.

pholser added 2 commits July 8, 2011 20:47
…ic type parameters. This commit comprises only those changes required in the core of JUnit -- basically adding a validator that the Theories runner can call to reject theories with generic type variables (that are hard to resolve), and deprecating FrameworkMethod#producesType, which only the Theories runner uses, and which will be supplanted by an equivalent method on ParameterSignature. Other required changes will be added to the Theories experiment once it migrates over to junit.contrib.
…ucesType. Adding acknowledgements entry for pholser. Starting 4.9.1 release notes.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

4.9.1, please. :-)

@dsaff
Copy link
Member

dsaff commented Jul 12, 2011

Excellent. Just the one fix (version number in release notes), and we're finally ready to go.

@pholser
Copy link
Contributor Author

pholser commented Jul 12, 2011

There we are. Thanks for your patience!

dsaff added a commit that referenced this pull request Jul 12, 2011
Disable theories with generic type parameters in core Theories runner.
@dsaff dsaff merged commit d94d5c8 into junit-team:4.9.1 Jul 12, 2011
@dsaff
Copy link
Member

dsaff commented Jul 12, 2011

Au contraire, thank you!

@avandeursen
Copy link
Contributor

I was running a little coverage analysis of all of JUnit, and it turns out the class NoGenericTypeParametersValidator provided in this pull request is never used.

The reason for that is that the test class provided in the pull request, WithUnresolvedGenericTypeVariablesOnTheoryParms, is not included in any suite.

The most logical solution seems adding it to the org.junit.tests.experimental.ExperimentalTests suite.

Doing that shows that the new tests fail. The reason for this is that the method FrameworkMethod.validateNoTypeParametersOnArgs(...) is never called.

Could it be that some code was missing in the pull request?

@dsaff
Copy link
Member

dsaff commented Dec 12, 2012

Hmm. @pholser, any thoughts?

@pholser
Copy link
Contributor Author

pholser commented Dec 12, 2012

Happy to have a look.

@pholser
Copy link
Contributor Author

pholser commented Dec 12, 2012

#572 should rectify the no-generic-parms validator missing execution/test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants