prepare testing splices, but cabal-install-3.4 does not build yet
authorJulien Moutinho <julm+symantic-parser@sourcephile.fr>
Fri, 22 Jan 2021 01:18:49 +0000 (02:18 +0100)
committerJulien Moutinho <julm+symantic-parser@sourcephile.fr>
Fri, 22 Jan 2021 01:18:49 +0000 (02:18 +0100)
default.nix
flake.lock
flake.nix
symantic-parser.cabal
test/Golden.hs

index 8193a1411ea3d46db003c101d850cb6886541b3e..6e261a6975b2bbbebce062af0ee6e25ab5727446 100644 (file)
@@ -8,7 +8,8 @@ let
     then pkgs.haskellPackages
     else pkgs.haskell.packages.${ghc};
   hs = haskellPackages.extend (with pkgs.haskell.lib;
-    hself: hsuper: {
+    hself: hsuper:
+    {
       data-fix = doJailbreak hsuper.data-fix;
       primitive = doJailbreak hsuper.primitive;
       assoc = doJailbreak hsuper.assoc;
@@ -25,8 +26,9 @@ in hs.symantic-parser // {
   shell = hs.shellFor {
     packages = p: [ p.symantic-parser ];
     nativeBuildInputs = [
-      pkgs.cabal-install
+      #pkgs.cabal-install
       #hs.cabal-install
+      pkgs.cabal-install
       #hs.haskell-language-server
       #hs.hpc
     ];
index f9d2ea9a5f9628a0b47ca8d670abedf907d716eb..52b801acb84560de96d83fc065cd3a828421520d 100644 (file)
@@ -2,11 +2,11 @@
   "nodes": {
     "flake-utils": {
       "locked": {
-        "lastModified": 1605370193,
-        "narHash": "sha256-YyMTf3URDL/otKdKgtoMChu4vfVL3vCMkRqpGifhUn0=",
+        "lastModified": 1610051610,
+        "narHash": "sha256-U9rPz/usA1/Aohhk7Cmc2gBrEEKRzcW4nwPWMPwja4Y=",
         "owner": "numtide",
         "repo": "flake-utils",
-        "rev": "5021eac20303a61fafe17224c087f5519baed54d",
+        "rev": "3982c9903e93927c2164caa727cd3f6a0e6d14cc",
         "type": "github"
       },
       "original": {
@@ -17,8 +17,8 @@
     },
     "nixpkgs": {
       "locked": {
-        "narHash": "sha256-HfBk+YMxtD/IgBalqi+QU/Pm/H7Iec0pFTKWM3YryZI=",
-        "path": "/nix/store/7drdr5lynw6hci9clz4qdxqwybn7qx4f-nixpkgs-patched",
+        "narHash": "sha256-hnTAIxykdSXGlYS1MCcuWCVRjQXEktGF10E3vOhMXaU=",
+        "path": "/nix/store/j50a2vrhcrl24y5ijlrfjcmbgswgjj9n-nixpkgs-patched",
         "type": "path"
       },
       "original": {
index 030eef931864f7c4d5b20fb4a04a9032c713c381..494305fd730ac34b83683f2ed296725f1b96387d 100644 (file)
--- a/flake.nix
+++ b/flake.nix
@@ -6,9 +6,7 @@ outputs = inputs:
     pkgs = inputs.nixpkgs.legacyPackages.${system};
     in {
       defaultPackage = import ./default.nix { inherit pkgs; };
-      devShell = (import ./default.nix {
-        inherit pkgs;
-      }).shell;
+      devShell = (import ./default.nix { inherit pkgs; }).shell;
     }
   );
 }
index fb81dd8309c7ed172c7284cd834fb0835ea3d5b5..5a60b1c8d729ac376695d64236aaec963451f4a9 100644 (file)
@@ -32,9 +32,11 @@ extra-source-files:
   shell.nix
   test/Golden/**/*.dump
   test/Golden/**/*.txt
+  test/Golden/Splice/**/*.hs
 extra-tmp-files:
 build-type: Simple
-tested-with: GHC==9.0.0
+-- build-type: Custom
+tested-with: GHC==9.0.1
 
 source-repository head
   type: git
@@ -76,6 +78,13 @@ common boilerplate
     -fhide-source-paths
     -freverse-errors
 
+-- custom-setup
+--   setup-depends:
+--     base      >= 4.14,
+--     Cabal     >= 3.0,
+--     directory >= 1,
+--     filepath  >= 1.3
+
 library
   import: boilerplate
   hs-source-dirs: src
@@ -118,12 +127,17 @@ test-suite symantic-parser-test
   main-is: Main.hs
   other-modules:
     Golden
+    --Golden.Splice
+    --Golden.Utils
+    Parser
     Parser.Brainfuck
     Parser.Nandlang
     Parser.Playground
-    -- Golden.Utils
+    --Paths_symantic_parser
     -- HUnit
     -- QuickCheck
+  -- autogen-modules:
+  --   Paths_symantic_parser
   default-extensions:
     ViewPatterns
   ghc-options:
@@ -146,6 +160,7 @@ test-suite symantic-parser-test
     text >= 1.2,
     -- time >= 1.9,
     transformers >= 0.4,
+    -- turtle >= 1.5,
     -- QuickCheck >= 2.0,
     -- tasty-quickcheck,
     unix >= 2.7,
index fc092b9f4f2d32919a09a2c18e1cc00021c1ca74..2782ac9bb0dba770a32c07728cf3d18c9845954a 100644 (file)
@@ -25,7 +25,7 @@ import qualified Language.Haskell.TH.Syntax as TH
 import qualified Symantic.Parser as P
 import qualified Symantic.Parser.Haskell as H
 import qualified Parser
---import Golden.Utils
+--import qualified Golden.Splice
 
 goldensIO :: IO TestTree
 goldensIO = return $ testGroup "Golden"
@@ -36,6 +36,7 @@ goldensIO = return $ testGroup "Golden"
   -- with and without --accept
   , goldensMachine
   , goldensParser
+  --, Golden.Splice.goldens
   ]
 
 goldensGrammar :: TestTree