Skip to content

Commit

Permalink
Add component target tests
Browse files Browse the repository at this point in the history
  • Loading branch information
philderbeast committed Jan 2, 2025
1 parent 4c54fc6 commit b25856d
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# cabal clean
# cabal v2-target
Configuration is affected by the following files:
- cabal.project
Resolving dependencies...
Fully qualified target forms:
- a:lib:a
29 changes: 29 additions & 0 deletions cabal-testsuite/PackageTests/Target/cabal.ctype-target.out
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# cabal clean
# cabal v2-target
Configuration is affected by the following files:
- cabal.project
Resolving dependencies...
Fully qualified target forms:
- a:lib:a
- a:lib:a-sublib
# cabal clean
# cabal v2-target
Configuration is affected by the following files:
- cabal.project
Resolving dependencies...
Fully qualified target forms:
- a:exe:a-exe
# cabal clean
# cabal v2-target
Configuration is affected by the following files:
- cabal.project
Resolving dependencies...
Fully qualified target forms:
- a:test:a-test
# cabal clean
# cabal v2-target
Configuration is affected by the following files:
- cabal.project
Resolving dependencies...
Fully qualified target forms:
- a:bench:a-bench
14 changes: 14 additions & 0 deletions cabal-testsuite/PackageTests/Target/cabal.test.hs
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,17 @@ main = do
cabal "v2-target" ["dir-a/"]
cabal "clean" []
cabal "v2-target" ["dir-a/", "--enable-tests", "--enable-benchmarks"]

cabalTest' "component-target" $ do
cabal "clean" []
cabal "v2-target" ["a:lib:a"]

cabalTest' "ctype-target" $ do
cabal "clean" []
cabal "v2-target" ["a:libs"]
cabal "clean" []
cabal "v2-target" ["a:exes"]
cabal "clean" []
cabal "v2-target" ["a:tests"]
cabal "clean" []
cabal "v2-target" ["a:benches"]

0 comments on commit b25856d

Please sign in to comment.