Quasiquote json to fix vim syntax highlighting

This commit is contained in:
Joe Nelson
2015-02-15 16:03:31 -08:00
parent e37d5d9b25
commit eea1bc0cac
+3 -3
View File
@@ -37,7 +37,7 @@ spec = beforeAll testSet . afterAll_ (clearTable "items") . around withApp $ do
it "matches with equality" $
get "/items?id=eq.5"
`shouldRespondWith` ResponseMatcher {
matchBody = Just "[{\"id\":5}]"
matchBody = Just [json| [{"id":5}] |]
, matchStatus = 200
, matchHeaders = ["Content-Range" <:> "0-0/1"]
}
@@ -60,14 +60,14 @@ spec = beforeAll testSet . afterAll_ (clearTable "items") . around withApp $ do
it "by a column asc" $
get "/items?id=lte.2&order=id.asc"
`shouldRespondWith` ResponseMatcher {
matchBody = Just "[{\"id\":1},{\"id\":2}]"
matchBody = Just [json| [{"id":1},{"id":2}] |]
, matchStatus = 200
, matchHeaders = ["Content-Range" <:> "0-1/2"]
}
it "by a column desc" $
get "/items?id=lte.2&order=id.desc"
`shouldRespondWith` ResponseMatcher {
matchBody = Just "[{\"id\":2},{\"id\":1}]"
matchBody = Just [json| [{"id":2},{"id":1}] |]
, matchStatus = 200
, matchHeaders = ["Content-Range" <:> "0-1/2"]
}