From dd1ab6dd3668f6aad419534ba9663043cdfe429d Mon Sep 17 00:00:00 2001 From: akhesaCaro Date: Fri, 5 Mar 2021 08:16:35 +0100 Subject: [PATCH 1/2] fixing DocSpec tests to make them compile --- .gitignore | 1 + servant-docs/test/Servant/DocsSpec.hs | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index a74ddee26..6cec8e9d7 100644 --- a/.gitignore +++ b/.gitignore @@ -30,6 +30,7 @@ doc/_build doc/venv doc/tutorial/static/api.js doc/tutorial/static/jq.js +shell.nix # nix result* diff --git a/servant-docs/test/Servant/DocsSpec.hs b/servant-docs/test/Servant/DocsSpec.hs index 5da5ff4d8..357beed89 100644 --- a/servant-docs/test/Servant/DocsSpec.hs +++ b/servant-docs/test/Servant/DocsSpec.hs @@ -126,8 +126,11 @@ spec = describe "Servant.Docs" $ do it "mentions headers" $ do md `shouldContain` "- This endpoint is sensitive to the value of the **X-Test** HTTP header." - it "contains response samples" $ - md `shouldContain` "{\"dt1field1\":\"field 1\",\"dt1field2\":13}" + it "contains response samples - dt1field1" $ + md `shouldContain` "\"dt1field1\":\"field 1\"" + it "contains response samples - dt1field2" $ + md `shouldContain` "\"dt1field2\":13" + it "contains request body samples" $ md `shouldContain` "17" From 269e546a6a6b4e293a5ed67250fa2f1154c48274 Mon Sep 17 00:00:00 2001 From: akhesaCaro Date: Thu, 18 Mar 2021 08:48:30 +0100 Subject: [PATCH 2/2] sqlite-simple cookbook is working with sqlite-simple >= 0.4.5.0 --- .gitignore | 1 - cabal.project | 5 +---- doc/cookbook/db-sqlite-simple/db-sqlite-simple.cabal | 2 +- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index 6cec8e9d7..a74ddee26 100644 --- a/.gitignore +++ b/.gitignore @@ -30,7 +30,6 @@ doc/_build doc/venv doc/tutorial/static/api.js doc/tutorial/static/jq.js -shell.nix # nix result* diff --git a/cabal.project b/cabal.project index b8516e66f..337ef6aee 100644 --- a/cabal.project +++ b/cabal.project @@ -26,7 +26,7 @@ packages: doc/cookbook/custom-errors doc/cookbook/basic-streaming doc/cookbook/db-postgres-pool - -- doc/cookbook/db-sqlite-simple + doc/cookbook/db-sqlite-simple doc/cookbook/file-upload doc/cookbook/generic -- doc/cookbook/hoist-server-with-context @@ -54,9 +54,6 @@ constraints: constraints: base-compat ^>=0.11 constraints: semigroups ^>=0.19 --- MonadFail --- https://github.com/nurpax/sqlite-simple/issues/74 -constraints: sqlite-simple < 0 -- allow-newer: sqlite-simple-0.4.16.0:semigroups -- allow-newer: direct-sqlite-2.3.24:semigroups diff --git a/doc/cookbook/db-sqlite-simple/db-sqlite-simple.cabal b/doc/cookbook/db-sqlite-simple/db-sqlite-simple.cabal index e8e1588fa..108b85c8e 100644 --- a/doc/cookbook/db-sqlite-simple/db-sqlite-simple.cabal +++ b/doc/cookbook/db-sqlite-simple/db-sqlite-simple.cabal @@ -23,7 +23,7 @@ executable cookbook-db-sqlite-simple , http-types >= 0.12 , markdown-unlit >= 0.4 , http-client >= 0.5 - , sqlite-simple >= 0.4 + , sqlite-simple >= 0.4.5.0 , transformers default-language: Haskell2010 ghc-options: -Wall -pgmL markdown-unlit