Commit graph

37 commits

Author SHA1 Message Date
Jon Gjengset
d5076883c5
Only require sudo for integration tests 2018-11-24 14:17:29 -05:00
Jon Gjengset
481ace22a6
Also test on Windows! 2018-11-24 14:17:29 -05:00
Jon Gjengset
1eab9c8375
Refine Travis CI build and add rustfmt/clippy
This patch modifies the Travis build pipeline to include multiple
[build stages](https://docs.travis-ci.com/user/build-stages/). CI now
progresses in the following steps:

 - First, `cargo check` is run on `stable` only.
   If it fails, the build is considered failed.
   This is so that we can fail fast for obviously botched commits.
 - Then, unit and doc tests are run for all targets.
   If any non-nightly tests fail, the build fails.
 - Then, integration tests with
   [GreenMail](http://www.icegreen.com/greenmail/) are run on Linux for
   all Rust targets. We can't run them on macOS because it doesn't
   support the Docker service.
   If any non-nightly tests fail, the build fails.
 - Then, `rustfmt` and `clippy` are both run on *beta* and on nightly.
   We use beta instead of stable to try to give ourselves some headroom
   for changes coming down the pike. The lints are only run on Linux,
   because the platform shouldn't matter.
   If any beta lints fail, the build fails.
 - And finally, we generate a coverage report on nightly on Linux.
   This can only run on nightly because tarpaulin requires nightly.
   It's only run on Linux, because we want to include integration tests.
   Note that the coverage stage has its own cache
   (`CACHE_NAME=coverage`) because the only thing it caches is cargo
   tarpaulin (the rust/cargo cache is cleaned before exit).

Fixes #48.
2018-11-24 14:17:29 -05:00
Jon Gjengset
cb9df750fd
Restart test server in case tests aren't reentrant
Specifically, if a test doesn't clean up nicely after itself, running it
a second time for checking coverage might make it fail! We restart the
docker server so that all the server state is erased, which should
mitigate that.
2018-11-24 00:57:07 -05:00
Jon Gjengset
26d8e8e333
Actually, now it's codecov.io 2018-11-22 20:57:18 -05:00
Jon Gjengset
74fc745618
Fix typo 2018-11-22 20:56:42 -05:00
Jon Gjengset
b75e30802a
No need to test --lib twice 2018-11-22 20:56:42 -05:00
Jon Gjengset
9be18cc574
No need to even install coverage on osx 2018-11-22 20:56:42 -05:00
Jon Gjengset
13a5638149
We're using coveralls.io 🤦 2018-11-22 20:56:41 -05:00
Jon Gjengset
9353493139
Make sure tests get run by coverage 2018-11-22 20:56:41 -05:00
Jon Gjengset
3e034585b3
Run Greenmail detched 2018-11-22 20:56:41 -05:00
Jon Gjengset
f4e1dc81b5
Only check coverage on stable 2018-11-22 20:56:41 -05:00
Jon Gjengset
b85e4cbe9a
No docker on osx 2018-11-22 20:56:41 -05:00
Jon Gjengset
4d9cd8c49a
Better code coverage maybe? 2018-11-22 20:56:41 -05:00
Jon Gjengset
c393fd7162
Add Travis integration testing
This uses [GreenMail's Docker
image](http://www.icegreen.com/greenmail/#deploy_docker_standalone) to
spin up a real SMTP+IMAP server on Travis, and then runs a series of
integration tests against it by sending e-mails using
[`lettre`](https://crates.io/crates/lettre) and checking that we can
receive them correctly.

A start on #101.
2018-11-22 20:56:41 -05:00
Jon Gjengset
6888dda451
Check all things in CI (inc. examples) 2018-04-03 13:03:51 -04:00
Jon Gjengset
dc21eae428
Workaround for travis-ci/travis-ci#9061 2018-01-22 19:55:38 -05:00
Matt McCoy
c7a1fa647e Add OSX build on Travis CI
Just to make sure we can build on OSX.
2017-10-04 20:13:31 -04:00
Jon Gjengset
f72c28aab7 Use cargo-tarpaulin instead of kcov/cargo-travis (#46) 2017-10-04 19:47:31 -04:00
Matt McCoy
32a1cabf6e Switch from travis-cargo to cargo-travis (#44)
travis-cargo no longer works with coveralls, and appears
to be unmaintained. This change use regular cargo to
build and test. It now uses cargo-travis to push test
results to coveralls. This will also build nightly, and 
only push test results on the stable build.
2017-10-02 19:52:21 -04:00
Matt McCoy
ecda5165fb Build with rust 1.20.0 in Travis CI 2017-10-01 20:29:44 -04:00
Jon Gjengset
300cfc04f8 Use docs.rs for documentation (#40)
* Use docs.rs for documentation

This would also allow deleting the `gh-pages` branch (which is pretty large).
I'd also recommend adding `badges` and `categories` to make the crates.io page more useful (see [this](http://www.integer32.com/2017/01/20/categories-and-ci-badges.html)), but I'll leave that up to you.

* Remove more references to old docs
2017-09-28 17:19:54 -04:00
Matt McCoy
55e860e8d4 Add a build for windows using appveyor (#37) 2017-07-12 17:05:32 -04:00
Matt McCoy
1ef94f86dc Compile using only the stable and beta versions of Rust 2017-03-02 17:31:56 -05:00
Matt McCoy
0eaf3709e6 Adding rust 1.9.0 to travis.yml for testing coveralls 2016-07-14 20:14:03 -04:00
Matt McCoy
26d0baa27e Remove quotes around exclude pattern 2016-07-14 20:08:10 -04:00
Matt McCoy
6992615921 Removing uneeded /.cargo exclude because it is included by default 2016-06-24 16:13:17 -04:00
Matt McCoy
016149d1c0 Adding travis cargo exclude pattern 2016-06-24 16:07:52 -04:00
Matt McCoy
40d0e9ff0e Removing rust nightly build 2016-06-16 19:38:08 -04:00
Matt McCoy
dcfa73e50d Updating .travis.yml to push test coverage to coveralls.io 2016-06-16 19:33:38 -04:00
Matt McCoy
fde5d39fb3 Removing unused security key for travis ci 2016-06-15 19:21:09 -04:00
Matt McCoy
e8e2dcd2d8 Adding encryption for GH_TOKEN for travis ci build 2016-06-15 19:05:43 -04:00
Matt McCoy
7eee407b25 Fixing to use stable version of rust 2016-06-15 18:50:04 -04:00
Matt McCoy
d73f1c7c33 Fixing indentation of .travis.yml 2016-06-15 18:48:01 -04:00
Matt McCoy
a124b9c157 chaning before_script to before_install 2016-06-15 18:43:24 -04:00
Matt McCoy
3e2aacf35d Adding travis-cargo to build for docs 2016-06-15 18:22:49 -04:00
Matt McCoy
95e6676055 Initial Commit 2015-04-15 16:23:58 -04:00