Commit Graph

25 Commits

Author SHA1 Message Date
Paul Osborne
90269e4d12 ci: fix docker container check
Newer version of docker no longer have the /.dockerinit file present
when the container is executing, so that is no longer an option.
When executing in a container, we do know that we will be executing
as pid 1 -- this is probably not ever the case on the host system.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-08-10 19:30:12 -05:00
Paul Osborne
b2835fce0a ci: push docs to gh-pages and code cov to coveralls
This moves things around a fair bit in the .travis.yml to be
more logically ordered and adds support for publishing docs
(on master) to gh-pages.  Code coverage is also calculated
and published to coveralls.io.

Travis is able to write to gh-pages on the github repository
via the GH_TOKEN environment variable stored in the travis
settings (marked as private).  This token is generated from
the github user 'rust-nix-bot' in order to avoid given access
to other repos associated with an actual user's account (this
practice is recommended by Github).

Other changes worth noting:
 - We now test fewer intermediate versions of rust
 - The existing logic to publish to Carl's S3 bucket have been removed.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-07-10 01:26:55 -05:00
Paul Osborne
c336e6df95 testing: specify a few extra environment variables
Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-21 23:18:06 -05:00
Paul Osborne
3813e045c5 testing: use posborne/rust-cross:x86 for x86_64/i686
Previously, std for x86_64 and i686 was included in the base
image.  To reduce size, those contents are now in the x86
image instead.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-21 23:16:03 -05:00
Paul Osborne
a6967d6110 travis: add back testing on all rust versions (for linux)
We are using containers for a majority of builds again, so perform
those builds on more platforms (as travis seems to handle this much
better).

For OSX, we now testing i686/x86_64 on 1.1.0 as well for added
coverage.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-17 11:36:52 -05:00
Paul Osborne
e18111bf21 testing: remove refs to test_nix in run-all.sh
Somewhere in the last set of changes, a few references to
`test_nix` were not removed.  Since that function doesn't exist,
the tests would never be run on those targets.

This script is only used when testing locally right now.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-16 14:47:58 -05:00
Paul Osborne
d1311ffbeb testing: ensure run.sh is executing in docker container
On the host, some undesired things could end up happening if this
is executed, so we now exit and log if that is attempted.  In addition,
we now backup the previous cargo config if present.  This will never
be the case in the current build setup, but that could change if
we decide to do builds in a data volume in the future.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-14 14:34:05 -05:00
Paul Osborne
72f6754275 testing: explicitly check TRAVIS_OS_NAME is osx
Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-14 14:10:38 -05:00
Paul Osborne
4e245f48ce testing: update documentation related to testing
Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-14 13:03:51 -05:00
Paul Osborne
5eb1fa6dcd testing: use default linker for appropriate platforms
For platforms where the host ${CC} is appropriate, use the default
implicitly rather than matching it explictly.  This will allow for the
llvm linker to be used if/when that happens.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-14 12:54:08 -05:00
Paul Osborne
02af925178 testing: move echo statement within docker run script
Based on code review feedback.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-14 12:52:33 -05:00
Paul Osborne
3b7b15d0a7 testing: docker tests now work on travis
All of the platforms tested currently fail in some way currently, but
the infrastructure itself appears to be working.  As we have moved to
the legacy infrastructure (required in order to use docker), the tests
do run slower now.  To compensate for that, i686 builds are only done on
stable and we do not test every version between the current stable and
the oldest version we support.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 16:19:20 -05:00
Paul Osborne
6ad81d1ce3 testing: first shot at testing with travis for arm, mips, android, ...
This is based on libc and the new docker-based testing infrastructure
via posborne/rust-cross.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 15:16:03 -05:00
Paul Osborne
cd3fdaf991 testing: move to new posborne/rust-cross images
The rust-cross image is no longer all-in-one but broken out by architecture
class (or platform in the case of android).

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 15:04:46 -05:00
Paul Osborne
b69558cd82 testing: fix gcc/linker paths for several targets
There are also changes in the upstream docker images to support
more targets (android on ARM, etc).
2016-03-13 00:41:07 -06:00
Paul Osborne
14e2f766fe testing: export CC based on .cargo/config contents
We already need to test cargo about gcc locations so it can perfom
linking -- we just parse this information out to tell rust where
gcc is for complation (nix-test compiles some C code for testing).

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:07 -06:00
Paul Osborne
5ddd8b2e22 testing: disable thread parallelization in docker testing
Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:06 -06:00
Paul Osborne
b5b7042e80 testing: fix test exeuction paths with move to docker container
Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:06 -06:00
Paul Osborne
d95f4d55cf testing: disable some targets and continue running on failure
Later on, it will probably make sense to stop on failure -- given
that most targets currently fail, however, this works a bit better
for the time being.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:05 -06:00
Paul Osborne
806e0a7833 testing: remove set -x from ci/run.sh
Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:05 -06:00
Paul Osborne
3f2b70af27 testing: allow the docker image to be overriden
This is handy for trying out changes to the docker image for
testing things out.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:05 -06:00
Paul Osborne
22b182029c testing: switch to posborne/rust-cross
There is now a published docker image (if a bit large) making
it possible for others to start using the new test ingfrastructure.
There seems to be no shortage of compile problems right now.

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:04 -06:00
Paul Osborne
b5a9227323 testing: add documentation covering the basics
Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:04 -06:00
Paul Osborne
6ffe725c7a testing: configure linker via .cargo/config
Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:04 -06:00
Paul Osborne
e6fff3a43a testing: add ci scripts to aid testing on more architectures/versions
These scripts represent a rough first cust at adding support for
locally building nix and its tests for a large number of rust
versions and architectures.  Currently, this mostly helps with
testing that nix compiles for various architectures (to the point that
there are a mound of problems that need to be addressed).  Once these
are sorted, the code for actually running the tests for various
architectures will be approached (this will require qemu and will
still not target all architectures).

Signed-off-by: Paul Osborne <osbpau@gmail.com>
2016-03-13 00:41:03 -06:00