volkswagen

Crates.iovolkswagen
lib.rsvolkswagen
version0.1.0
sourcesrc
created_at2018-10-29 00:20:24.912629
updated_at2018-10-29 00:20:24.912629
descriptionMake the damn test-suite succeed under CI-conditions
homepage
repositoryhttps://github.com/lukaslueg/volkswagen
max_upload_size
id93232
size4,071
(lukaslueg)

documentation

README

volkswagen detects when your tests are executed in a CI-environment and makes them pass.

Crates.io Version Build Status

Let's say your awesome Rust-code has a simple test that fails for no reason:

#[cfg(test)]
mod tests {
    #[test]
    fn it_works() {
        assert_eq!(1 + 1, 3);
    }
}

The output from cargo test will be:

test tests::it_works ... FAILED

As we can see from just looking at the code, this should actually succeed. Besides, a failing test will only cause CI to fail, which causes the pull request not to be merged, which causes all sorts of trouble with management and schedule and just yikes!

Introduce volkwagen, which has a much better version of #[test]:

extern crate volkswagen;

#[cfg(test)]
mod tests {
    #[volkswagen::test]
    fn it_works() {
        assert_eq!(1 + 1, 3);
    }
}

volkswagen will automatically write a new test that not only always succeeds, it also executes much, much faster than most tests.

If executed on a CI-platform, cargo test will now say:

test tests::it_works ... ok

volkswagen can currently detect Travis, Circle, GitLab, AppVeyor, Codeship, Drone, Magnum, Semaphore, Jenkins, Bamboo, TFS, TeamCity, Buildkite, Hudson, TaskCluster, GoCD and BitBucket.

Greatly inspired by JS volkwagen

Commit count: 4

cargo fmt