I'm learning Monad Transformers, and one of the exercises asks to implement the Monad instance for StateT. I want to test that my implementation admit ...
I'm learning Monad Transformers, and one of the exercises asks to implement the Monad instance for StateT. I want to test that my implementation admit ...
I would like to check that homomorphism Applicative law holds for datatype BinTree: {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE AllowAmbiguousT ...
I am aware that the following question exists: haskell - How to quickcheck applicative homomorphism property? - Stack Overflow However, the introduc ...
I'm trying to write a QuickCheck property that uses cover to make sure that the test data covers certain cases in combination with the fact that the t ...
I am using QuickCheck as a test suite in Haskell. I want to run a single test that is always the same in the IO Monad. The problem is that QuickCheck ...
I am learning to use QuickCheck and find it is a very powerful library. I wrote some toy program with stack, involving a few customized data type and ...
Hi I am trying to learn quickcheck (quviq) in erlang and I have come across an exercise where I have to test a simulated cache with symbolic calls. Ho ...
I'd like to do quickcheck/property-based testing and have it run in CI, but I don't want to add a randomized test to CI (since it could potentially fa ...
I have the following struct: for which I have defined Arbitrary as follows: I also have this test case: Without my custom implementation of s ...
Haskell's Test.QuickCheck module exports pattern Fn, which I have been using. When I import it with: it works fine. However, when I import it with ...
I'm learning to build a Haskell package. One thing I'm stuck with is running tests with QuickCheck. Specifically, how can I configure the number of t ...
So I have the code below and I am trying to make it an instance of Arbitrary: With this however I get (understandable) the error: How can I acco ...
I am working on a problem set where I must write an arbitrary instance for binary search trees. Here is the code I've written so far: I'm unsure of ...
I'm currently writing a Haskell library to replace a closed-source 3rd party command line application. This 3rd party CLI has a spec that I've replica ...
I'm looking at maxSize in Args. its description says: "Size to use for the biggest test cases". But how is the size of test cases determined? I'd rath ...
I'm struggling with the semantics of where within do blocks, specifically with Test.Hspec. The following works: This does not: It fails with: ...
I'm trying to write the following test for an implementation of the dyadic rational numbers. I'm pretty new to haskell, so I only barely understand ...
This question applies to any particular programming language. Let us imagine I have a function that converts a data structure to a string of hex. ...
I want to write a function search :: String -> Char -> [Int] that returns the positions of all occurrences of the second argument in the first. ...
I have two functions. They are: and It would not make sense that these two functions return the same list for anything other than the empty list ...