-
-
Couldn't load subscription status.
- Fork 289
Add specs2 support #88
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
Conversation
|
Can one of the admins verify this patch? |
|
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed, please reply here (e.g.
|
|
CLA bot got it wrong again. |
|
There are some things we are not sure about. Currently in order to use the new rules, you need to add following lines to project WORKSPACE file: Another thing we'd appreciate feedback on is how we produce a list of test classes from the jar (we use Do you have any recommendations on xml output? |
|
👍🏽 thanks!
|
|
Sorry for the delay. I've been on vacation. Will look tomorrow. Thanks for
|
| def specs2(): | ||
|
|
||
| # org.specs2:specs2-common_2.11:jar:3.8.4 | ||
| native.maven_jar( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is already in the @scala target. Can we not use that one?
|
can we add tests here? One thing I am concerned about is that the dependencies of specs2 are a bit heavier. So, there is a decent chance a user is going to already have some of these dependencies in their tree. How can we deal with that? I think that we need to move to using |
| implementation=_scala_specs2_test_impl, | ||
| attrs={ | ||
| "main_class": attr.string(default="org.junit.runner.JUnitCore"), | ||
| "_specs2_all": attr.label(default=Label("//specs2:specs2_with_junit"), allow_files=True), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe we can just have a junit target, and then in a macro, etc... have junit + specs. Some might just want to run a junit test without any specs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and/or the target can be a bind variable, and the users can set up what to point to.
|
@ittaiz great to meet you and chat with you today! |
|
decided to implement it a bit differently in the end. I implemented JUnit support and added specs2 on top of that (requires usage of |
|
Given that @ittaiz found a way to run specs2 on top of junit, I am closing this PR as no longer relevant. |
Adding two rules to run specs2 tests:
Junit xml output is not yet supported.
Rules tested in:
https://github.com/mvaitkus/bazel_scala_sample