-
Notifications
You must be signed in to change notification settings - Fork 841
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4498 from NorfairKing/detailed-test-bug-regressio…
…n-test Integration test to showcase failure with detailed-0.9 test type
- Loading branch information
Showing
9 changed files
with
193 additions
and
11 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
cabal-version: 1.12 | ||
|
||
-- This file has been generated from package.yaml by hpack version 0.31.1. | ||
-- | ||
-- see: https://github.com/sol/hpack | ||
-- | ||
-- hash: 6a3d670e6f645b1ae099ce4d47325765448bfe194c0f497059a5fe3524388288 | ||
|
||
name: http-download | ||
version: 0.1.0.0 | ||
synopsis: Verified downloads with retries | ||
category: Development | ||
homepage: https://github.com/commercialhaskell/http-download#readme | ||
bug-reports: https://github.com/commercialhaskell/http-download/issues | ||
author: Michael Snoyman | ||
maintainer: [email protected] | ||
copyright: 2018-2019 FP Complete | ||
license: MIT | ||
build-type: Simple | ||
|
||
source-repository head | ||
type: git | ||
location: https://github.com/commercialhaskell/http-download | ||
|
||
library | ||
exposed-modules: | ||
Network.HTTP.Download | ||
Network.HTTP.Download.Verified | ||
other-modules: | ||
Paths_http_download | ||
hs-source-dirs: | ||
src/ | ||
build-depends: | ||
base | ||
, base64-bytestring | ||
, bytestring | ||
, conduit | ||
, conduit-extra | ||
, cryptonite | ||
, cryptonite-conduit | ||
, directory | ||
, exceptions | ||
, filepath | ||
, http-client | ||
, http-conduit | ||
, http-types | ||
, memory | ||
, path | ||
, path-io | ||
, retry | ||
, rio | ||
, rio-prettyprint | ||
default-language: Haskell2010 | ||
|
||
test-suite spec | ||
type: exitcode-stdio-1.0 | ||
main-is: Spec.hs | ||
other-modules: | ||
Network.HTTP.Download.VerifiedSpec | ||
Paths_http_download | ||
hs-source-dirs: | ||
test | ||
build-depends: | ||
base | ||
, cryptonite | ||
, hspec | ||
, http-client | ||
, http-download | ||
, path | ||
, path-io | ||
, retry | ||
, rio | ||
, rio-prettyprint | ||
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,48 @@ | ||
cabal-version: 1.12 | ||
|
||
-- This file has been generated from package.yaml by hpack version 0.31.1. | ||
-- | ||
-- see: https://github.com/sol/hpack | ||
-- | ||
-- hash: 4695b863639ee3242a4625aad63f566d63d6a52a61d08e2792516e6219a12f45 | ||
|
||
name: rio-prettyprint | ||
version: 0.1.0.0 | ||
synopsis: Pretty-printing for RIO | ||
category: Development | ||
homepage: https://github.com/commercialhaskell/rio-prettyprint#readme | ||
bug-reports: https://github.com/commercialhaskell/rio-prettyprint/issues | ||
author: Michael Snoyman | ||
maintainer: [email protected] | ||
copyright: 2018-2019 FP Complete | ||
license: MIT | ||
build-type: Simple | ||
|
||
source-repository head | ||
type: git | ||
location: https://github.com/commercialhaskell/rio-prettyprint | ||
|
||
library | ||
exposed-modules: | ||
RIO.PrettyPrint | ||
RIO.PrettyPrint.DefaultStyles | ||
RIO.PrettyPrint.StylesUpdate | ||
RIO.PrettyPrint.Types | ||
Text.PrettyPrint.Leijen.Extended | ||
other-modules: | ||
Paths_rio_prettyprint | ||
hs-source-dirs: | ||
src/ | ||
build-depends: | ||
Cabal | ||
, aeson | ||
, annotated-wl-pprint | ||
, ansi-terminal | ||
, array | ||
, base | ||
, colour | ||
, mtl | ||
, path | ||
, rio | ||
, text | ||
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,7 @@ | ||
import StackTest | ||
import System.Directory | ||
|
||
main :: IO () | ||
main = do | ||
removeDirIgnore ".stack-work" | ||
stack [defaultResolverArg, "test"] |
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,3 @@ | ||
resolver: lts-11.22 | ||
packages: | ||
- '.' |
18 changes: 18 additions & 0 deletions
18
test/integration/tests/4453-detailed/files/test-detailed-example.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,18 @@ | ||
name: test-detailed-example | ||
version: 0.1.0.0 | ||
build-type: Simple | ||
cabal-version: >=1.20 | ||
|
||
library | ||
hs-source-dirs: src | ||
exposed-modules: Lib | ||
build-depends: base >= 4.7 && < 5 | ||
default-language: Haskell2010 | ||
|
||
test-suite test-detailed-example-test | ||
type: detailed-0.9 | ||
hs-source-dirs: test | ||
test-module: Spec | ||
build-depends: base >= 4.7, | ||
Cabal >= 1.20 | ||
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,21 @@ | ||
module Spec (tests) where | ||
|
||
import Distribution.TestSuite | ||
|
||
tests :: IO [Test] | ||
tests = do | ||
return [ | ||
test "foo" Pass | ||
, test "bar" (Fail "It did not work out!") | ||
] | ||
|
||
test :: String -> Result -> Test | ||
test name r = Test t | ||
where | ||
t = TestInstance { | ||
run = return (Finished r) | ||
, name = name | ||
, tags = [] | ||
, options = [] | ||
, setOption = \_ _ -> Right t | ||
} |