Unit Tests & Integration Tests

Matthew Williams matthew.williams at canonical.com
Thu Sep 11 15:29:44 UTC 2014


Hi Folks,

There seems to be a general push in the direction of having more mocking in
unit tests. Obviously this is generally a good thing but there is still
value in having integration tests that test a number of packages together.
That's the subject of this mail - I'd like to start discussing how we want
to do this. Some ideas to get the ball rolling:

Having integration tests spread about the package and having environment
variables that switch on/ off them being run

$ JUJU_INTEGRATION go test ./...

We could make use of build tags:

$ go test -tags integration ./...

We could put all the integration tests in a single package:

$ go test github.com/juju/juju/integrationtests/...


Thoughts?

Matty
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/juju-dev/attachments/20140911/65d2b5b5/attachment.html>


More information about the Juju-dev mailing list