Request: scalacheck with effectful properties
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 15/100
Direzione di ricerca
This is an open design discussion, not a defined change. The payload names no files. It mentions the scalacheck integration, where properties must be pure, and a proposed forall variant that takes an IO[Expectations] body. Read the existing scalacheck integration to see how properties are run, then settle the design in the thread. Done means an agreed API and a per-run logger approach, which a maintainer has to decide first.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
I'm using weaver + scalacheck, where my properties are actually IO programs that I evaluate with TestControl.executeEmbed(fullTask).unsafeRunSync().
The IO is part of the interface I'm testing, but in tests I'm injecting nonblocking dependencies (i.e. an in-memory stub KV store instead of a real DB). So everything is actually synchronous, but the interface still needs to be IO.
This seems like a bit of a gap with the current scalacheck integration, where properties must be pure. Perhaps I'm stretching the definition of a property, but all I really want to do is run a program and make assertions over an array of different generated inputs. TBH even if the properties involved real IO, using scalacheck still seems valid and useful (even if it's potentially slow / expensive compared to pure properties).
One concrete issues I have is that my properties include logging. Unfortunately, they all share the same logger, so when e.g. example 80 fails, I get the logs for 79 successful tests and one failed test.
So, creating an issue to track/discuss support for IO in scalacheck properties. Features I'd like:
- a version of forall where the body/property returns IO[Expectations]
- potentially using the IO monad's parallelism, instead of (or as well as?) scalacheck's parallelism
- a separate logger per run, so only the failed run's logs are printed
- Lingua principale
- Scala
- Stelle
- 87
- Fork
- 17
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di typelevel/weaver-test
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 65/100
typelevel/weaver-test#302 · 3 commenti · 1 reazione ·
-
Remove or filter weaver log levelsForse di nuovo libera @Sukuna0007Abhi l’ha presa 287 giorni fa e non c’è nessuna pull request aperta. Aperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
typelevel/weaver-test#262 · 2 commenti ·
-
Support for tag filteringAperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
typelevel/weaver-test#233 · 3 commenti · 2 reazioni ·
-
`MutableSuiteTest` is flakyAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 52/100
typelevel/weaver-test#201 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
typelevel/weaver-test#180 ·
Tutte le issue di typelevel/weaver-test
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
canton-network/splice#8342 ·
I maintainer di solito rispondono entro 1 giorno
-
bug genc
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno
-
`estimateTip` caps the estimated tip at 2147483647Forse già presa @RaphaelFakhri l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
software-mansion/starknet-jvm#644 ·
I maintainer di solito rispondono entro 2 giorni
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
propensive/soundness#2424 ·
I maintainer di solito rispondono entro 1 giorno
-
? - Needs Triage bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
NVIDIA/cudf-spark#16741 ·
I maintainer di solito rispondono entro 1 giorno