178 Commits

Author SHA1 Message Date
Dale Wijnand
05400b8018
Drop the [/] test output macro 2018-08-02 10:18:48 +01:00
Dale Wijnand
67c52ffe58
Add tests for per-target edition
Test:
* enabling edition feature & setting at target level (happy path)
* overriding the package-level edition with per-target edition
* feature gating of per-target edition
* per-target edition usage for rustdoc
2018-07-31 14:49:33 +01:00
Dale Wijnand
ca7d9ee292
Declare one-line files on one line, in test projects 2018-07-25 09:58:50 +01:00
Dale Wijnand
ab19c48358
Dedup a bunch more manifest 2018-07-25 00:43:30 +01:00
Dale Wijnand
081e7930d2
Drop now unnecessary basic manifests 2018-07-24 16:33:55 +01:00
Dale Wijnand
43b42d6f4c
Reorganise the testsuite crate module hierarchy
* Collapse the nested cargotest::support module into the cargotest
  module (merge the mod.rs's)
* Rename the cargotest module to support
* Nest the top-level hamcrest module into support
2018-07-22 08:46:44 +01:00
Eric Huss
c3b477d495 Support --cap-lints in rustdoc. 2018-07-21 20:17:03 -07:00
Dale Wijnand
f8c9928cc1
Rework some test projects to use the "foo" default
Generally that means either switching "foo" and "bar" around (reversing
the arrow), or it means push "foo" to "bar" (and sometimes "bar" to
"baz", etc..) to free up "foo".

For trivia that leaves 80/1222 outliers, therefore 93.4% of test
project use the default. :)
2018-07-21 19:40:45 +01:00
Dale Wijnand
6da2ada26d
Migrate trailing calls to project with an argument
.. in docs, commented code & tests targetting non-macos.
2018-07-20 15:25:51 +01:00
Dale Wijnand
7fe2fbc8a3
Remove the argument from the project test support function
By rewriting the tests, with rerast (https://github.com/google/rerast),
to use the newly introduced "at" method.

First I added the following temporary function to cargotest::support:

    pub fn project_foo() -> ProjectBuilder {
        project("foo")
    }

Then I defined the following rewrite.rs:

    use cargotest::support::{ project, project_foo };

    fn rule1(a: &'static str) {
        replace!(project("foo") => project_foo());
        replace!(project(a) => project_foo().at(a));
    }

Then I ran rerast:

    cargo +nightly rerast --rules_file=rewrite.rs --force --targets tests --file tests/testsuite/main.rs

Finally I searched and replaced the references to project_foo with
argument-less project (a little awkardly on macOS with a git clean).

    find tests -type f -exec sed -i -e 's/project_foo/project/g' {} +
    git clean -d tests
2018-07-20 13:31:50 +01:00
bors
06721dd6b6 Auto merge of #5543 - roblabla:doc-private-items, r=alexcrichton
Add document-private-items flag to cargo doc

Add a `--document-private-items` flag to `cargo doc`, that mimics the equivalent `cargo rustdoc -- --document-private-items`. This works by relaying the flag to the underlying rustdoc call.
2018-07-16 00:26:07 +00:00
roblabla
7757753b28 Verify that private items were actually documented 2018-07-15 20:22:22 +02:00
roblabla
4a11afc59f Add a test for document-private-items 2018-07-15 20:10:01 +02:00
Esteve Fernandez
1286b841e9 Disable cargo doc --open tests on Windows and macOS. 2018-05-29 12:34:31 +02:00
Esteve Fernandez
a0cf04e066 Added two more tests: one where a package contains a library and a binary and another where it only contains a binary. 2018-05-29 12:23:50 +02:00
Esteve Fernandez
8f3be0626f Use [/] instead of hardcoded / so that it's portable on Windows. 2018-05-29 12:05:41 +02:00
Esteve Fernandez
2309420106 Don't pass --open as an argument. 2018-05-29 12:05:36 +02:00
Esteve Fernandez
3d63b12f7c Added test where the name of the library is different from the package's. 2018-05-29 11:55:29 +02:00
Eric Huss
3dbae343ac Fix passing --edition to rustdoc during doctests.
Fixes #5538
2018-05-15 09:29:34 -07:00
Alex Crichton
8413008937 Rename the rust manifest key to edition
This'll hopefully jive better with the terminology of "edition" throughout the
rest of Rust!
2018-05-03 11:45:04 -07:00
Eric Huss
575d6e819c Profile Overrides (RFC #2282 Part 1) 2018-04-27 13:22:00 -07:00
varkor
97b971a775 Update tests to check for Checking 2018-04-19 19:19:11 +01:00
Richard Dodd
066f9a02c9 Better test description 2018-04-15 14:00:36 +01:00
Richard Dodd
466196959f [Wip] fix issue 5345 2018-04-15 13:56:22 +01:00
Eric Huss
187bb0ad9a Don't use .arg() in test. 2018-04-05 06:04:45 -07:00
Eric Huss
bbb2b92ef8 Pass edition to rustdoc.
Fixes #5279.
2018-04-05 05:39:50 -07:00
Alex Crichton
1e6828485e cargo fmt 2018-03-14 17:48:23 -07:00
André Rocha
c2ff988c9f Reorganize integration tests as one crate with many modules. Issue #4867. 2018-02-21 13:33:51 -05:00