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

Avoid non-JS compatible APIs for ScalaTest #176

Closed
wants to merge 3 commits into from

Conversation

armanbilge
Copy link
Member

Not sure if this is too hacky, but this is working on both JVM and JS in circe/circe-fs2#272. The createDefaultScheduler doesn't work on Scala.js.

The alternative is a full cross, or maybe an upstream PR to CE itself.

@armanbilge
Copy link
Member Author

Initial CI failure was unrelated, it was for the utest framework. See a similar failure in c8dac77.

@djspiewak
Copy link
Member

This is a little hacky. :-) Why doesn't createDefaultScheduler work on JavaScript? It's present and does the right thing.

@armanbilge
Copy link
Member Author

For some reason I was getting link-time errors?

@armanbilge
Copy link
Member Author

armanbilge commented Jul 27, 2021

@djspiewak I bumped circe-fs2 to CE 3.2.0 just in case and still get this:

[error] Referring to non-existent method cats.effect.unsafe.IORuntime$.createDefaultScheduler(java.lang.String)scala.Tuple2
[error]   called from cats.effect.testing.scalatest.AsyncIOSpec.$init$()void
[error]   called from constructor io.circe.fs2.Fs2Suite.<init>()void
[error]   called from static constructor io.circe.fs2.Fs2Suite.<stinit>()void
[error]   called from core module analyzer
[error] Referring to non-existent method cats.effect.unsafe.IORuntime$.createDefaultScheduler$default$1()java.lang.String
[error]   called from cats.effect.testing.scalatest.AsyncIOSpec.$init$()void
[error]   called from constructor io.circe.fs2.Fs2Suite.<init>()void
[error]   called from static constructor io.circe.fs2.Fs2Suite.<stinit>()void
[error]   called from core module analyzer
[error] Referring to non-existent method cats.effect.unsafe.IORuntime$.createDefaultScheduler$default$1()java.lang.String
[error]   called from cats.effect.testing.scalatest.AsyncIOSpec.$init$()void
[error]   called from constructor io.circe.fs2.Fs2Suite.<init>()void
[error]   called from static constructor io.circe.fs2.Fs2Suite.<stinit>()void
[error]   called from core module analyzer
[error] Referring to non-existent method cats.effect.unsafe.IORuntime$.createDefaultScheduler(java.lang.String)scala.Tuple2
[error]   called from cats.effect.testing.scalatest.AsyncIOSpec.$init$()void
[error]   called from constructor io.circe.fs2.Fs2Suite.<init>()void
[error]   called from static constructor io.circe.fs2.Fs2Suite.<stinit>()void
[error]   called from core module analyzer

@armanbilge
Copy link
Member Author

Wait, I think I realized the problem ... the build.sbt for cats-effect-testing neglects to use %%% :(

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