Commit Graph

48 Commits

Author SHA1 Message Date
Jacob Hoffman-Andrews 10f7c506b2 Merge branch 'master' into bump_go_1.5.2 2015-12-06 12:42:51 -08:00
Jeff Hodges 23813a737f bump Go version to 1.5.2 2015-12-05 18:30:08 -08:00
Jacob Hoffman-Andrews 33b8c357ef Split out setup.sh from travis-before-install.
This accomplishes two things:
 - setup.sh should now be usable by the client integration test.
 - setup.sh can be used by new project members to simplify first setup.

Update the README to indicate the new file, and to correct some out-of-date
information.
2015-11-30 23:44:45 -08:00
bifurcation dff15243df Merge branch 'master' into 1.5.1 2015-10-09 15:58:46 -04:00
Jacob Hoffman-Andrews ed7c31f0ca Spurious diff to trigger Travis. 2015-10-08 16:26:15 -07:00
Jeff Hodges 43040e7f04 bump go to 1.5.1 in travis
We don't want to put multiple versions in our config because it'll
launch another set of sub-builds and eat up our quota.
2015-10-07 20:29:35 -07:00
Jacob Hoffman-Andrews b3aca1ff2b Speed up tests.
Make `make` aware of output files so it doesn't always have to rebuild. Also
make it use `go install`, which is faster than building files individually.

Now that make is faster, use it in startservers.py to consolidate building
logic. This also has the handy side-effect that ./start.py exposes useful build
information through /build, whereas before only the .rpm packaged version did.

Additionally, this allows us to remove `make` from the Travis matrix, since we
are running `make` as part of the integration test. This means each PR only
triggers two Travis builds instead of one, which means we will get results from
Travis faster.

Also, change the Travis matrix logic to be a list of actions to run, rather than
a list of actions to skip. That fixes
https://github.com/letsencrypt/boulder/issues/817.

Enumerate specific sections of test.sh to run, rather than sections to skip.

Note: ./start.py now installs into ./bin/ instead of $GOPATH/bin.

Only set up GitHub secret file (for PR status reporting) when available, and
decrypt it into /tmp rather than $HOME, to avoid accidentally caching it once
Travis' caching features are available.

Clone letsencrypt repo into $HOME instead of $TMP, to make it possible to cache
eventually.

Remove unused `mysql` dependency in Travis.

Override default Travis install command to prevent it from adding
Godeps/_workspace to GOPATH. When that happens, it hides failures that should
arise from importing non-vendorized paths.
2015-10-01 16:28:17 -07:00
Jacob Hoffman-Andrews 7555c89b22 Add building for test branches. 2015-09-20 20:56:42 -07:00
Jacob Hoffman-Andrews 69ddcb784c Add a test that there are no outdated migrations.
If a branch merges with a migration that is timestamped earlier than other
migrations already in master, that migration may get skipped.
2015-09-18 14:53:40 -07:00
Jeff Hodges f5f588acd9 retry download of go binaries in Travis
bitbucket is espescially slow and flaky. Not doing this caused a test
failure on master.

We should probably figure out a solution for keeping binaries
around. (Godeps doesn't solve that trivially.)
2015-09-02 12:58:34 -07:00
Jeff Hodges 0d1af54d17 run make in parallel in TravisCI
This gets us down to 5-6 minute build times.

A new script had to be added to run make conditionally without allowing
builds with make failures to pass.
2015-09-01 16:50:27 -07:00
Jeff Hodges c77fcaf8e8 only build letsencrypt in TravisCI when needed
The unit test part of the build matrix doesn't need letsencrypt
downloaded and built, so only do it when needed.

Also, use travis_retry in test.sh for git and pip work to compensate
better.
2015-08-27 14:47:39 -07:00
Jeff Hodges fb56e35a00 run unit and integration tests at the same time 2015-08-27 14:08:11 -07:00
Jeff Hodges 7b6f2894f7 add goose as the migration tool
This has required some substantive changes to the tests. Where
previously the foreign key constraints did not exist in the tests, now
that we use the actual production schema, they do. This has mostly led
to having to create real Registrations in the sa, ca, and ra tests. Long
term, it would be nice to fake this out better instead of needing a real
sa in the ca and ra tests.

The "goose" being referred to is <https://bitbucket.org/liamstask/goose>.

Database migrations are stored in a _db directory inside the relevant
owner service (namely, ca/_db, and sa/_db, today).

An example of migrating up with goose:

    goose -path ./sa/_db -env test up

An example of creating a new migration with goose:

    goose -path ./sa/_db -env test create NameOfNewMigration sql

Notice the "sql" at the end. It would be easier for us to manage sql
migrations. I would like us to stick to only them. In case we do use Go
migrations in the future, the underscore at the beginning of "_db" will
at least prevent build errors when using "..." with goose-created Go
files. Goose-created Go migrations do not compile with the go tool but
only with goose.

Fixes #111
Unblocks #623
2015-08-25 12:02:31 -07:00
Jacob Hoffman-Andrews f9b66733a2 Run tests on Go 1.5. 2015-08-19 23:57:41 -07:00
Jeff Hodges b08e6e0bad use MariaDB in integration tests and start.py
This changes moves from using SQLite in the integration tests and in the
test/boulder-config.json.

It does not port the unit tests over, unfortunately. That's a much more
invasive change.

This also updates the Dockerfile to include the MariaDB and RabbitMQ
requirements of start.py as well as adjusts the CMD to expose the
boulder server to the host machine. The Dockerfile also needed to have
its Go version bumped and the test.sh had to grow some explict
"function"s.

Updates #132
2015-08-07 23:22:52 -07:00
Roland Shoemaker 65df2e9c93 Fix duplicated addons sections 2015-07-31 21:08:28 -07:00
Roland Shoemaker c4b31889bd Remove bootstrap 2015-07-31 11:50:02 -07:00
Roland Shoemaker 6530a9d95d Switch to travis containers 2015-07-31 11:45:18 -07:00
Jeff Hodges ee9c09b6d8 add host to travis set up for integration tests 2015-07-31 02:11:29 -07:00
Jakub Warmuz 247d18a390
Fix hyphens in letsencrypt install command.
Corresponds to https://github.com/letsencrypt/letsencrypt/pull/600.
2015-07-11 05:39:18 +00:00
Jakub Warmuz 95503a058d
Update installation command for letsencrypt client.
Corresponds to https://github.com/letsencrypt/letsencrypt/pull/598
2015-07-10 22:25:29 +00:00
Jeff Hodges efbc518cbc do not update PR if coming from non-maintainer
The github-secret.json file can't be decrypted if the PR is coming from
someone who is not a maintainer on boulder. So, just use the boring old
status updates from TravisCI and let the tests continue to run.
2015-07-09 19:01:11 -07:00
J.C. Jones 2a649b4ab1 Rework per @rolandshoemaker & regenerated secret 2015-07-02 08:56:55 -07:00
J.C. Jones dcde7936ec Switch to golang-implementation of `github-pr-status`. 2015-07-01 16:55:23 -07:00
J.C. Jones 4d3731ba73 Issue #419 - Provide more details from Travis on PRs.
This uses a node.js module to post `status` updates to Github, and uses a Travis
secret to authenticate.

- Post comments from static analysis tools
- Change to posting from LetsEncryptBot
- For integration testing, only fail if the compile fails, or
  the NodeJS-client fails. Log if the Python client fails.
2015-06-30 15:32:50 -07:00
Jakub Warmuz f8b3750c02
Run letsencrypt/tests/boulder-integration.sh from integration tests. 2015-06-26 06:32:10 +00:00
Jacob Hoffman-Andrews ee4626aa0d Integration test runs without root. 2015-06-19 14:12:23 -07:00
William Budington 76d76d33cd Adding integration tests.
Travis:
  * Downloads the Let's Encrypt client
  * Installs system requirements for client
  * Sets up virtualenv

Dockerfile:
  * Buildout for development
  * Includes numerous pacakges needed for integration testing
    (including all of the above in Travis)

test.sh:
  * If no path is defined for the LE client
    * Download the Let's Encrypt client
    * Set up virtualenv

test/amqp-integration-test.py:
  * Run client test with sensible defaults
  * One test: auth for foo.com
2015-06-19 12:18:23 -07:00
Jacob Hoffman-Andrews 5dcb620cde Pass if directory already exists. 2015-06-18 17:51:18 -07:00
Jacob Hoffman-Andrews 079f019533 Support forked-repo Travis build. 2015-06-18 16:57:39 -07:00
Roland Shoemaker af3abc97f6 add amqp-integration-test.py and use it in test.sh, also tell travis to give us RabbitMQ 2015-06-02 12:02:05 -07:00
J.C. Jones 2c020f9da0 Configure Travis to only build master on pushes 2015-05-14 14:23:42 -07:00
J.C. Jones ed32332204 First pass at build speedups. Feel free to use `make -j9` on your desktops! 2015-05-14 11:37:23 -07:00
J.C. Jones 821d3c6bdd Issue #171: Attempt to catch the build failure with Travis 2015-05-11 13:11:16 -07:00
Jacob Hoffman-Andrews c7c5617b6c Remove unnecessary go get. 2015-03-25 18:55:49 -07:00
Jacob Hoffman-Andrews ddc0d7dcf5 Vendorize all dependencies with `nut`.
Nut, https://github.com/jingweno/nut, is a tool to manage Go dependencies and
versioning by vendorizing them, i.e. including them in your own repo.

This makes version management easier, as well as authenticating the contents of
this repository.

Also inthis change: Factor out the testing commands from .travis.yml to make it
easier to run them by hand. Add Vim swap files to .gitignore.
2015-03-25 15:11:40 -07:00
Richard Barnes 24bafe98c6 Fixing issues from jsha review 2015-03-13 12:31:41 -07:00
J.C. Jones 9d9ad5f1ab Fix a 'vet' issue, and more travis cleaning
It'd be nice if I could simulate a travis build locally first...
2015-03-11 08:37:33 -06:00
J.C. Jones a3f843bf97 Update coverage commands for Travis. 2015-03-11 08:18:45 -06:00
J.C. Jones a28a0e729c Stop building against golang-tip (for now). 2015-02-19 11:58:29 -07:00
J.C. Jones aca80d476b Add coverage figures.
- Added Gover to the list so that we can use subpackages (like analysisengine)
2015-02-19 11:42:28 -07:00
Jeff Hodges ff7fb2b20e indent travis file 2015-01-28 18:10:25 -08:00
Jeff Hodges a6276eda4e newline, again 2015-01-28 16:38:25 -08:00
Jeff Hodges 4e84b0c765 add go vet, go lint, and covermode
There are failures found with these tools that is not found by travis
without them (including the "package bouler" typo in #10).
2015-01-28 16:20:50 -08:00
Jeff Hodges af10672a88 add newline to .travis.yml 2015-01-28 15:17:04 -08:00
Jeff Hodges b073c375e9 remove unneeded install info 2015-01-28 14:57:14 -08:00
Jeff Hodges 4ba0095546 really add travis YAML file 2015-01-28 14:42:22 -08:00