Merge lp://staging/~jameinel/goose/test-script into lp://staging/~gophers/goose/trunk
Status: | Merged |
---|---|
Merged at revision: | 49 |
Proposed branch: | lp://staging/~jameinel/goose/test-script |
Merge into: | lp://staging/~gophers/goose/trunk |
Diff against target: |
177 lines (+173/-0) 1 file modified
test.py (+173/-0) |
To merge this branch: | bzr merge lp://staging/~jameinel/goose/test-script |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Dimiter Naydenov (community) | Approve | ||
Review via email:
|
Commit message
test.py: Add test.py as a way to ensure the test suite gets run in a consistent way.
Description of the change
This adds a test.py script to goose.
This was designed to be run by the tarmac bot, but it should be something that we can use ourselves.
The biggest thing that it provides today is 'py test.py --live' which will:
a) Run 'go build'
b) Run 'go test ./...'
c) Go to each directory with live tests and run 'go test -live -gocheck.v'
This is a little bit redundant, because -live also runs the regular tests. But we don't have a great way (yet) to cd into every directory and run the tests (./...) while also passing a parameter that only some sets provide.
This also will play some tricks about setting your GOPATH, which would let you work in 'any directory you want' as long as it has 'src/launchpad.
It also provides a 'py test.py --tarmac' flag, which does all the setup infrastructure we will need for tarmac to operate properly. (set up shared repositories, ensure juju-core and its dependencies are installed, etc.)
It doesn't yet have a flag for "and run the juju-core trunk tests as well", but I'll probably be adding that next.
Very nice! We should start using it regularly.