Skip to content
This repository has been archived by the owner on Feb 1, 2021. It is now read-only.

Proposal: PoC for Bats integration tests #443

Merged
merged 1 commit into from
Mar 4, 2015

Conversation

chanwit
Copy link
Contributor

@chanwit chanwit commented Mar 3, 2015

Swarm requires integration tests (#376) and @aluzzardi suggested in #400 that Swarm should use Bats to run this kind of tests. This PR follows Docker Machine's way of testing (docker/machine#615). It proposes a PoC to perform integration tests for Swarm.

There are 2 tests under test/integration directory:

  1. A test to match version and gitcommit.
  2. A test that uses timeout to check if Swarm fail to connect to a non-existed node.

To run these tests:

  1. Compile swarm and make sure that there's the binary in $GOBIN.
  2. Run bats test/integration

/cc @vieux

Signed-off-by: Chanwit Kaewkasi [email protected]

@bacongobbler
Copy link
Contributor

should the directory be renamed to integration-cli(similar to docker) or test/integration? That seems to be the common directory structure, though really that's a matter of whether the dress is white and gold or blue and black.

@chanwit
Copy link
Contributor Author

chanwit commented Mar 3, 2015

@bacongobbler Thank you for your comments. I just follow how Docker Machine does for its testing directory. I am fine to change it to any better name.

@aluzzardi
Copy link
Contributor

Thanks @chanwit, this is really awesome!

I would probably do test/integration, I imagine eventually we'd have test/stress and so on.

@chanwit
Copy link
Contributor Author

chanwit commented Mar 3, 2015

done renaming to test/integration.

Signed-off-by: Chanwit Kaewkasi <[email protected]>
aluzzardi added a commit that referenced this pull request Mar 4, 2015
Proposal: PoC for Bats integration tests
@aluzzardi aluzzardi merged commit fd8ff48 into docker-archive:master Mar 4, 2015
@aluzzardi
Copy link
Contributor

Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants