Skip to content

Commit 3dd3d54

Browse files
authored
Merge pull request #150 from haskell-works/disable-integration-tests
Disable integration tests by default
2 parents a79d6a3 + f17a175 commit 3dd3d54

File tree

4 files changed

+14
-6
lines changed

4 files changed

+14
-6
lines changed

.circleci/config.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ workflows:
4949
context: haskell-ci
5050
binary-cache-uri: ${BINARY_CACHE_URI-"http://hw-binary-cache-us-west-2-a.s3-website-us-west-2.amazonaws.com/archive"}
5151
cabal-build-extra: --write-ghc-environment-files=ghc8.4.4+
52-
cabal-test-extra: --test-show-details=direct --test-options='+RTS -g1'
52+
cabal-test-extra: --test-show-details=direct --flag it --test-options='+RTS -g1'
5353

5454
- haskell/build-with-binary-cache:
5555
name: GHC 8.6.5
@@ -60,7 +60,7 @@ workflows:
6060
context: haskell-ci
6161
binary-cache-uri: ${BINARY_CACHE_URI-"http://hw-binary-cache-us-west-2-a.s3-website-us-west-2.amazonaws.com/archive"}
6262
cabal-build-extra: --write-ghc-environment-files=ghc8.4.4+
63-
cabal-test-extra: --test-show-details=direct --test-options='+RTS -g1'
63+
cabal-test-extra: --test-show-details=direct --flag it --test-options='+RTS -g1'
6464

6565
- haskell/build-with-binary-cache:
6666
name: GHC 8.8.3
@@ -71,7 +71,7 @@ workflows:
7171
context: haskell-ci
7272
binary-cache-uri: ${BINARY_CACHE_URI-"http://hw-binary-cache-us-west-2-a.s3-website-us-west-2.amazonaws.com/archive"}
7373
cabal-build-extra: --write-ghc-environment-files=ghc8.4.4+
74-
cabal-test-extra: --test-show-details=direct --test-options='+RTS -g1'
74+
cabal-test-extra: --test-show-details=direct --flag it --test-options='+RTS -g1'
7575

7676
- haskell/build-with-binary-cache:
7777
name: GHC 8.10.1
@@ -82,7 +82,7 @@ workflows:
8282
context: haskell-ci
8383
binary-cache-uri: ${BINARY_CACHE_URI-"http://hw-binary-cache-us-west-2-a.s3-website-us-west-2.amazonaws.com/archive"}
8484
cabal-build-extra: --write-ghc-environment-files=ghc8.4.4+
85-
cabal-test-extra: --test-show-details=direct --test-options='+RTS -g1'
85+
cabal-test-extra: --test-show-details=direct --flag it --test-options='+RTS -g1'
8686

8787
- merge-point/merge-point:
8888
name: Build Ok

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -228,10 +228,10 @@ With [Docker Compose](./docker-compose.yml) this variable is used to configure K
228228
$ docker-compose up
229229
```
230230

231-
After that, tests can be run as usual:
231+
After that, integration tests can switched on with using 'it' flag:
232232

233233
```
234-
$ cabal test --test-show-details=direct
234+
$ cabal test --test-show-details=direct --flag it
235235
```
236236

237237
## Credits

hw-kafka-client.cabal

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ flag examples
3232
manual: True
3333
default: False
3434

35+
flag it
36+
description: Run integration tests
37+
manual: True
38+
default: False
39+
3540
library
3641
hs-source-dirs: src
3742
ghc-options: -Wall
@@ -103,6 +108,8 @@ test-suite integration-tests
103108
, text
104109
, transformers
105110
build-tool-depends: hspec-discover:hspec-discover
111+
if !(flag(it))
112+
buildable: False
106113
other-modules: Kafka.IntegrationSpec
107114
Kafka.TestEnv
108115
default-language: Haskell2010

shell.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ with import <nixpkgs> {};
22

33
pkgs.mkShell {
44
buildInputs = with pkgs; [
5+
openssl
56
zlib
67
rdkafka
78
nettools

0 commit comments

Comments
 (0)