Skip to content
This repository was archived by the owner on Oct 4, 2020. It is now read-only.

Commit 286006f

Browse files
committed
actual changes
1 parent b2633c5 commit 286006f

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

src/Test/StrongCheck.purs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ import Test.StrongCheck.Arbitrary (class Arbitrary, arbitrary, class Coarbitrary
4545
import Test.StrongCheck.LCG (Seed, mkSeed) as Exports
4646

4747
-- | A type synonym for StrongCheck effects in Eff.
48-
type SC eff a = Eff (console :: CONSOLE, random :: RANDOM, err :: EXCEPTION | eff) a
48+
type SC eff a = Eff (console :: CONSOLE, random :: RANDOM, exception :: EXCEPTION | eff) a
4949

5050
-- | The result of a property test.
5151
data Result = Success | Failed String
@@ -160,7 +160,7 @@ statCheckPure s freq prop = try 100
160160
defState :: Seed -> GenState
161161
defState s = (GenState {seed: s, size: 10})
162162

163-
check :: forall eff prop f. (Testable prop, Foldable f) => (prop -> f (Tuple Seed Result)) -> prop -> SC eff Unit
163+
check :: forall eff prop f. Testable prop => Foldable f => (prop -> f (Tuple Seed Result)) -> prop -> SC eff Unit
164164
check f prop = do
165165
let results = f prop
166166
let successes = countSuccesses results
@@ -196,7 +196,7 @@ infix 1 annotate as <?>
196196

197197
-- | Asserts that two values are equal, resulting in a `Failure` if they are
198198
-- | not, with a message showing the values involved.
199-
assertEq :: forall a. (Eq a, Show a) => a -> a -> Result
199+
assertEq :: forall a. Eq a => Show a => a -> a -> Result
200200
assertEq a b = a == b <?> msg
201201
where
202202
msg = show a <> " /= " <> show b
@@ -205,7 +205,7 @@ infix 2 assertEq as ===
205205

206206
-- | Asserts that two values are not equal, resulting in a `Failure` if they
207207
-- | are, with a message showing the values involved.
208-
assertNotEq :: forall a. (Eq a, Show a) => a -> a -> Result
208+
assertNotEq :: forall a. Eq a => Show a => a -> a -> Result
209209
assertNotEq a b = a /= b <?> msg
210210
where
211211
msg = show a <> " == " <> show b

src/Test/StrongCheck/Data/ArbDateTime.purs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@ instance arbitraryArbTime ∷ Arbitrary ArbTime where
3131

3232
instance coarbitraryArbTimeCoarbitrary ArbTime where
3333
coarbitrary (ArbTime t) = do
34-
coarbitrary $ fromEnum (DT.hour t)
35-
coarbitrary $ fromEnum (DT.minute t)
36-
coarbitrary $ fromEnum (DT.second t)
34+
_ <- coarbitrary $ fromEnum (DT.hour t)
35+
_ <- coarbitrary $ fromEnum (DT.minute t)
36+
_ <- coarbitrary $ fromEnum (DT.second t)
3737
coarbitrary $ fromEnum (DT.millisecond t)
3838

3939
newtype ArbDate = ArbDate DT.Date
@@ -55,8 +55,8 @@ instance arbitraryArbDate ∷ Arbitrary ArbDate where
5555

5656
instance coarbitraryArbDateCoarbitrary ArbDate where
5757
coarbitrary (ArbDate dt) = do
58-
coarbitrary $ fromEnum (DT.year dt)
59-
coarbitrary $ fromEnum (DT.month dt)
58+
_ <- coarbitrary $ fromEnum (DT.year dt)
59+
_ <- coarbitrary $ fromEnum (DT.month dt)
6060
coarbitrary $ fromEnum (DT.day dt)
6161

6262
newtype ArbDateTime = ArbDateTime DT.DateTime
@@ -74,5 +74,5 @@ instance arbitraryArbDateTime ∷ Arbitrary ArbDateTime where
7474

7575
instance coarbitraryArbDateTimeCoarbitrary ArbDateTime where
7676
coarbitrary (ArbDateTime dt) = do
77-
coarbitrary $ ArbDate (DT.date dt)
77+
_ <- coarbitrary $ ArbDate (DT.date dt)
7878
coarbitrary $ ArbTime (DT.time dt)

src/Test/StrongCheck/Landscape.purs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ sampleHere :: forall a. Perturb a => Int -> Landscape a -> Array a
109109
sampleHere n = (<$>) (unDriverState >>> \v -> v.value) <<< sampleHere' n
110110

111111
-- | Moves to a location in a landscape that was previously sampled.
112-
moveTo :: forall a. (Eq a, Perturb a) => a -> Landscape a -> Maybe (Landscape a)
112+
moveTo :: forall a. Eq a => Perturb a => a -> Landscape a -> Maybe (Landscape a)
113113
moveTo a v = Landscape <$> moveIt a v
114114
where moveIt a' = force <<< L.head <<< L.filter (\v' -> (unDriverState (head v')).value == a') <<< tail <<< unLandscape
115115

src/Test/StrongCheck/Perturb.purs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ k0 = Math.log(maxNumber + 1.0)
273273
square :: Number -> Number
274274
square = flip Math.pow 2.0
275275

276-
toDist :: forall f. (Foldable f, Functor f) => f Number -> Number
276+
toDist :: forall f. Foldable f => Functor f => f Number -> Number
277277
toDist xs = Math.sqrt (sum $ square <$> xs)
278278

279279
delta :: Number -> Number -> Number

0 commit comments

Comments
 (0)