File tree Expand file tree Collapse file tree 4 files changed +21
-7
lines changed Expand file tree Collapse file tree 4 files changed +21
-7
lines changed Original file line number Diff line number Diff line change @@ -117,7 +117,7 @@ test-suite spec
117
117
, directory
118
118
, exceptions
119
119
, hspec == 2. *
120
- , hspec-wai
120
+ , hspec-wai >= 0.8 && < 0.9
121
121
, http-types
122
122
, network >= 2.6
123
123
, QuickCheck
Original file line number Diff line number Diff line change @@ -211,11 +211,17 @@ errorRetrySpec =
211
211
212
212
it " should continue when URLs don't match" $ do
213
213
request methodPost " " [jsonCT, jsonAccept] jsonBody
214
- `shouldRespondWith` 200 { matchBody = Just $ encode (8 :: Int ) }
214
+ `shouldRespondWith` 200 { matchBody = mkBody $ encode (8 :: Int ) }
215
215
216
216
it " should continue when methods don't match" $ do
217
217
request methodGet " a" [jsonCT, jsonAccept] jsonBody
218
- `shouldRespondWith` 200 { matchBody = Just $ encode (4 :: Int ) }
218
+ `shouldRespondWith` 200 { matchBody = mkBody $ encode (4 :: Int ) }
219
+ where
220
+ mkBody b = MatchBody $ \ _ b' ->
221
+ if b == b'
222
+ then Nothing
223
+ else Just " body not correct\n "
224
+
219
225
220
226
-- }}}
221
227
------------------------------------------------------------------------------
Original file line number Diff line number Diff line change @@ -10,10 +10,12 @@ extra-deps:
10
10
- control-monad-omega-0.3.1
11
11
- cryptonite-0.6
12
12
- doctest-0.11.0
13
- - hspec-2.2.3
14
- - hspec-core-2.2.3
15
- - hspec-discover-2.2.3
16
- - hspec-expectations-0.7.2
13
+ - hspec-2.3.2
14
+ - hspec-discover-2.3.2
15
+ - hspec-core-2.3.2
16
+ - hspec-wai-0.8.0
17
+ - hspec-expectations-0.8.2
18
+ - call-stack-0.1.0
17
19
- http-api-data-0.3
18
20
- natural-transformation-0.4
19
21
- primitive-0.6.1.0
Original file line number Diff line number Diff line change @@ -10,4 +10,10 @@ extra-deps:
10
10
- http-api-data-0.3
11
11
- servant-js-0.9 # needed for tutorial
12
12
- natural-transformation-0.4
13
+ - hspec-2.3.2
14
+ - hspec-discover-2.3.2
15
+ - hspec-core-2.3.2
16
+ - hspec-wai-0.8.0
17
+ - hspec-expectations-0.8.2
18
+ - call-stack-0.1.0
13
19
resolver : lts-6.0
You can’t perform that action at this time.
0 commit comments