From 3085707669b296cdcfad62b1748fb114b50751ea Mon Sep 17 00:00:00 2001 From: Shayne Fletcher Date: Sat, 30 Mar 2024 07:00:59 +0900 Subject: [PATCH] re-enable windows (disabled since move to 'get-tested') --- .github/workflows/ci.yml | 7 ++++--- placeholder.cabal | 1 + t/Test.hs | 7 ++++--- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c54e5d0..909bc20 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,12 +1,12 @@ name: haskell ci -on: +on: push: pull_request: workflow_dispatch: jobs: generate-matrix: name: "Generate matrix from cabal" - outputs: + outputs: matrix: ${{ steps.set-matrix.outputs.matrix }} runs-on: ubuntu-latest steps: @@ -17,6 +17,7 @@ jobs: cabal-file: placeholder.cabal ubuntu-version: latest macos-version: latest + windows-version: latest version: 0.1.7.0 tests: name: ${{ matrix.ghc }} on ${{ matrix.os }} @@ -25,7 +26,7 @@ jobs: strategy: fail-fast: false matrix: ${{ fromJSON(needs.generate-matrix.outputs.matrix) }} - steps: + steps: - uses: actions/checkout@v4 - uses: haskell-actions/setup@v2 id: setup-haskell diff --git a/placeholder.cabal b/placeholder.cabal index 4ce6cc9..dcf8ef4 100644 --- a/placeholder.cabal +++ b/placeholder.cabal @@ -35,6 +35,7 @@ common test import: base hs-source-dirs: t build-depends: + filepath >= 1.4, placeholder, tasty >= 1.2, tasty-hunit >= 0.10.0 diff --git a/t/Test.hs b/t/Test.hs index 577f3f2..014788b 100644 --- a/t/Test.hs +++ b/t/Test.hs @@ -5,6 +5,7 @@ import Control.Exception import Control.Monad (when) import Control.Placeholder import Data.List +import System.FilePath(()) import Test.Tasty import Test.Tasty.HUnit @@ -32,13 +33,13 @@ todoTest = do assertBool ("unexpected HasCallStack format: " ++ msg) $ all has [ "CallStack (from HasCallStack):" - , "todo, called at t/Test.hs:27:47 in main:Main" + , "todo, called at t" "Test.hs:28:47 in main:Main" ] when (has "CallStack (from -prof)") $ --enable-profiling enabled assertBool ("unexpected -prof stack format: " ++ msg) $ all has [ - "Control.Placeholder.todo (src/Control/Placeholder.hs:116:1-66)" - , "Main.todoTest (t/Test.hs:(26,1)-(43,7))" + "Control.Placeholder.todo (src" "Control" "Placeholder.hs:116:1-66)" + , "Main.todoTest (t" "Test.hs:(27,1)-(44,7))" , "Main.CAF ()" ]