Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support more return types for the @Parameters method. Fixes #700. #702

Merged
merged 1 commit into from
Jul 16, 2013

Conversation

stefanbirkner
Copy link
Contributor

Support the return types Iterator<? extends Object>, Object[] and Object[][]. You don't have to wrap arrays with Iterables and single parameters with Object arrays.

@@ -281,15 +313,24 @@ public Parameterized(Class<?> klass) throws Throwable {
return runners;
}

private Runner createRunner(String pattern, int index,
Copy link
Member

Choose a reason for hiding this comment

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

Can you give this a slightly different name just to make absolutely sure we don't get odd overloading effects on later changes?

@dsaff
Copy link
Member

dsaff commented Jul 8, 2013

Nice. One quick request.

@stefanbirkner
Copy link
Contributor Author

@dsaff I renamed the method.

@@ -281,15 +313,25 @@ public Parameterized(Class<?> klass) throws Throwable {
return runners;
}

private Runner createRunnerWithNotNormalizedParameters(String pattern,
Copy link
Member

Choose a reason for hiding this comment

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

Formatting looks weird here now.

@stefanbirkner
Copy link
Contributor Author

@dsaff Cleaned up formatting.

@dsaff
Copy link
Member

dsaff commented Jul 12, 2013

@stefanbirkner, FYI, it's a little easier to track in a review if we wait until the end to squash extra commits. But looks good now. Can you resolve merge conflicts, and I'll pull? Thanks.

…m#700.

Support the return types Iterator<? extends Object>, Object[] and Object[][]. You don't have to wrap arrays with Iterables and single parameters with Object arrays.
@stefanbirkner
Copy link
Contributor Author

I rebased to current master.

@dsaff Thanks for the advice about squashing.

dsaff pushed a commit that referenced this pull request Jul 16, 2013
Support more return types for the @parameters method. Fixes #700.
@dsaff dsaff merged commit 2a010a8 into junit-team:master Jul 16, 2013
@dsaff
Copy link
Member

dsaff commented Jul 16, 2013

@stefanbirkner, many thanks!

Would you mind adding a note at https://github.com/junit-team/junit/wiki/4.12-release-notes ? Thanks.

@stefanbirkner stefanbirkner deleted the parameterized-with-one-arg branch July 16, 2013 01:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants