Request: scalacheck with effectful properties
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 15/100
Línea de trabajo
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.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
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
- Lenguaje dominante
- Scala
- Estrellas
- 87
- Forks
- 17
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de typelevel/weaver-test
-
Dificultad 3/5 1-2 días Aptitud para principiantes 65/100
typelevel/weaver-test#302 · 3 comentarios · 1 reacción ·
-
Remove or filter weaver log levelsQuizá libre de nuevo @Sukuna0007Abhi la tomó hace 287 días y no hay ningún pull request abierto. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
typelevel/weaver-test#262 · 2 comentarios ·
-
Support for tag filteringAbierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 35/100
typelevel/weaver-test#233 · 3 comentarios · 2 reacciones ·
-
`MutableSuiteTest` is flakyAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 52/100
typelevel/weaver-test#201 ·
-
Dificultad 4/5 3-5 días Aptitud para principiantes 25/100
typelevel/weaver-test#180 ·
Todos los issues de typelevel/weaver-test
Issues similares
-
Spark benchmarks crash with `[INVALID_DRIVER_MEMORY]` on JVMs whose default heap is below Spark's ~450 MB minimumPosiblemente ocupada @sendaoYan la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 79/100
-
SEO
Dificultad 1/5 1-3 horas Aptitud para principiantes 87/100
lichess-org/lila#22409 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
canton-network/splice#8342 ·
Los mantenedores suelen responder en 1 día
-
bug genc
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
Los mantenedores suelen responder en 1 día
-
`estimateTip` caps the estimated tip at 2147483647Posiblemente ocupada @RaphaelFakhri la tomó hace 1 día. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
software-mansion/starknet-jvm#644 ·
Los mantenedores suelen responder en 2 días