Skip to content

Conversation

bcarter97
Copy link


trait CatsResourceIO[A] extends CatsResource[IO, A] with RuntimePlatform { this: FixtureAsyncTestSuite =>

override implicit def executionContext: ExecutionContext = ExecutionContext.global
Copy link
Author

Choose a reason for hiding this comment

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

Without this CatsResourceAllocationSpecs will fail

@bcarter97 bcarter97 force-pushed the 300-serial-ec-for-resource-suite branch from edef036 to 084f7ee Compare March 9, 2024 20:59
@bcarter97
Copy link
Author

bcarter97 commented Mar 9, 2024

Can't use the Global EC for Scala JS - don't have any experience with ScalaJS, should I follow the recommendation and use scala.scalajs.concurrent.JSExecutionContext.queue or is there a preferred method

After changing to use JS Global EC, it seems a bunch of imports aren't working (to do with the Scalatest Eventually trait). This is required to check the Resource is shutdown correctly. I think it would be possible to add a rudimentary eventually impl that doesn't require the Eventually trait, but I'd like some clarification on the approach

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.

CatsResourceIO in scalatest doesn't release the resource

1 participant