-
Notifications
You must be signed in to change notification settings - Fork 842
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Detect invalid flag specifications #617
- Loading branch information
Showing
18 changed files
with
149 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import StackTest | ||
|
||
main :: IO () | ||
main = stack ["build"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
resolver: ghc-7.8 | ||
flags: | ||
text: | ||
integer-simple: false | ||
extra-deps: | ||
- text-1.2.0.3 | ||
packages: [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import StackTest | ||
|
||
main :: IO () | ||
main = do | ||
stack ["build"] | ||
stackErr ["build", "--flag", "foo:bar"] | ||
stackErr ["build", "--flag", "files:bar"] | ||
stack ["build", "--flag", "*:bar"] |
10 changes: 10 additions & 0 deletions
10
test/integration/tests/617-unused-flag-cli/files/files.cabal
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
name: files | ||
version: 0.1.0.0 | ||
build-type: Simple | ||
cabal-version: >=1.10 | ||
|
||
library | ||
hs-source-dirs: src | ||
exposed-modules: Lib | ||
build-depends: base >= 4.7 && < 5 | ||
default-language: Haskell2010 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
module Lib | ||
( someFunc | ||
) where | ||
|
||
someFunc :: IO () | ||
someFunc = putStrLn "someFunc" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
resolver: ghc-7.8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import StackTest | ||
|
||
main :: IO () | ||
main = stackErr ["build"] |
10 changes: 10 additions & 0 deletions
10
test/integration/tests/617-unused-flag-name-yaml/files/files.cabal
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
name: files | ||
version: 0.1.0.0 | ||
build-type: Simple | ||
cabal-version: >=1.10 | ||
|
||
library | ||
hs-source-dirs: src | ||
exposed-modules: Lib | ||
build-depends: base >= 4.7 && < 5 | ||
default-language: Haskell2010 |
6 changes: 6 additions & 0 deletions
6
test/integration/tests/617-unused-flag-name-yaml/files/src/Lib.hs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
module Lib | ||
( someFunc | ||
) where | ||
|
||
someFunc :: IO () | ||
someFunc = putStrLn "someFunc" |
4 changes: 4 additions & 0 deletions
4
test/integration/tests/617-unused-flag-name-yaml/files/stack.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
resolver: ghc-7.8 | ||
flags: | ||
files: | ||
does-not-exist: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import StackTest | ||
|
||
main :: IO () | ||
main = stackErr ["build"] |
10 changes: 10 additions & 0 deletions
10
test/integration/tests/617-unused-flag-yaml/files/files.cabal
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
name: files | ||
version: 0.1.0.0 | ||
build-type: Simple | ||
cabal-version: >=1.10 | ||
|
||
library | ||
hs-source-dirs: src | ||
exposed-modules: Lib | ||
build-depends: base >= 4.7 && < 5 | ||
default-language: Haskell2010 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
module Lib | ||
( someFunc | ||
) where | ||
|
||
someFunc :: IO () | ||
someFunc = putStrLn "someFunc" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
resolver: ghc-7.8 | ||
flags: | ||
does-not-exist: | ||
foo: false |