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

Property Module: Mutation of global PropertyTesting fix for Kotlin/Native #2469

Merged
merged 14 commits into from
Sep 7, 2021

Conversation

nicorichard
Copy link
Contributor

Fixes #2440

Allows Kotlin/Native modification of the PropertyTesting configuration object's properties.

  • Introduced an expect/actual abstraction for AtomicReference which allows us to use atomicity in the common source for thread-safe mutations.
  • Added an accessory AtomicProperty which allows get/set delegation by ReadWriteProperty to use Atomic properties like common Kotlin variables.

@sksamuel sksamuel self-requested a review September 7, 2021 20:50
@sksamuel
Copy link
Member

sksamuel commented Sep 7, 2021

Native memory models is a bit out of my wheelhouse but I think I basically follow it. Could probably use this for the config for the main framework too (do you use kotest framework or just kotest prop test?)

@sksamuel sksamuel merged commit 7c67c8c into kotest:master Sep 7, 2021
@nicorichard
Copy link
Contributor Author

We've just been using prop-test so far, but looking at io.kotest.engine.config.ConfigManager I expect to see similar issues and most likely even calls to fun initialize might fail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants