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

bump scala 2.13 to latest milestone (M5) #78

Merged
merged 1 commit into from
Feb 11, 2019

Conversation

jozic
Copy link
Contributor

@jozic jozic commented Feb 6, 2019

No description provided.

@ultrasecreth
Copy link
Member

@jozic Please fix the scalatest dependency

@jozic
Copy link
Contributor Author

jozic commented Feb 7, 2019

i see that more work is required here
will try to address this soon

@jozic
Copy link
Contributor Author

jozic commented Feb 7, 2019

@bbonanno on 2.13.0-M5 vararg tests fail with

[info] - should work with varargs and multiple param lists *** FAILED ***
[info]   org.mockito.exceptions.verification.WantedButNotInvoked: Wanted but not invoked:
[info] org.fooWithVarArgAndSecondParameterList(
[info]     eqTo(cow),
[info]     <any>
[info] );
[info] -> at user.org.mockito.IdiomaticMockitoTest.$anonfun$new$71(IdiomaticMockitoTest.scala:431)
[info] 
[info] However, there was exactly 1 interaction with this mock:
[info] org.fooWithVarArgAndSecondParameterList(
[info]     ArraySeq(cow),
[info]     Cheese(Gouda)
[info] );
[info] -> at user.org.mockito.IdiomaticMockitoTest.$anonfun$new$71(IdiomaticMockitoTest.scala:429)
[info]   at user.org.mockito.IdiomaticMockitoTest.$anonfun$new$71(IdiomaticMockitoTest.scala:431)
[info]   at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:12)
[info]   at org.scalatest.OutcomeOf.outcomeOf(OutcomeOf.scala:85)
[info]   at org.scalatest.OutcomeOf.outcomeOf$(OutcomeOf.scala:83)
[info]   at org.scalatest.OutcomeOf$.outcomeOf(OutcomeOf.scala:104)
[info]   at org.scalatest.Transformer.apply(Transformer.scala:22)
[info]   at org.scalatest.Transformer.apply(Transformer.scala:20)
[info]   at org.scalatest.WordSpecLike$$anon$3.apply(WordSpecLike.scala:1075)
[info]   at org.scalatest.TestSuite.withFixture(TestSuite.scala:196)
[info]   at org.scalatest.TestSuite.withFixture$(TestSuite.scala:195)
[info]   ...

any suggestions?

@ultrasecreth
Copy link
Member

@jozic Scala 2.13.0-M5 uses ArraySeq.ofRef[_] instead of mutable.WrappedArray[_], so the pattern match for varargs fails, it needs to be updated

@ultrasecreth
Copy link
Member

@jozic let me know if it gets nasty and I'll take care of it

@jozic
Copy link
Contributor Author

jozic commented Feb 8, 2019

@bbonanno i think i made Travis happy
check the code please

@ultrasecreth
Copy link
Member

@jozic Looks good!

One thing that worries me a bit is how the different versions of ScalaTest and Scalactic could play as most of the people would be using 3.0.5...

Could you please do an sbt publishLocal and verify that adding this new release to an existing project this dependencies do not break anything? (in the meantime I'll try to automate some test like it in Travis)

Cheers

@jozic
Copy link
Contributor Author

jozic commented Feb 9, 2019

@bbonanno
I can do it, but probably not earlier than Monday. Will post an update here

@jozic
Copy link
Contributor Author

jozic commented Feb 11, 2019

@bbonanno
I've published new version locally and used that on my project. Works fine.
But my project (maven) specifies version of scalatest as 3.0.5, so mockito-scala can't override it, not sure if this is a good test, but also not sure if anyone else does it differently (not specifying scalatest version)

I also rebased on latest release

@ultrasecreth ultrasecreth merged commit 5465c3c into mockito:release/1.x Feb 11, 2019
@ultrasecreth
Copy link
Member

@jozic Thanks for that, and that's exactly what I wanted to check, I was afraid of people providing 3.0.5 and having some sort of nasty side effect, but if it works I'm happy to merge it

Many thanks for the contribution, much appreciated

@jozic jozic deleted the patch-1 branch February 12, 2019 18:06
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.

None yet

2 participants