Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extend compiletest to support subdirectories #31749

Merged
merged 7 commits into from
Feb 26, 2016

Conversation

nikomatsakis
Copy link
Contributor

You can now group tests into directories like run-pass/borrowck or compile-fail/borrowck. By default, all .rs files within any directory are considered tests: to ignore some directory, create a placeholder file called compiletest-ignore-dir (I had to do this for several existing directories).

r? @alexcrichton
cc @brson

@nikomatsakis
Copy link
Contributor Author

Hopefully we can use this to make it so that compile-fail and run-pass can actually be listed in GH again rather than surpassing some "don't show me this" threshold. :)

@pnkfelix
Copy link
Member

Sweet!

We should move all of the internal data checking tests that use rustc_fail into their own dedicated sub directory after this lands!

@nikomatsakis
Copy link
Contributor Author

@pnkfelix yeah, I was thinking that it'd be nice to:

  • move the existing ad-hoc subdirectories into their own subdirectories, so that things are more obviously grouped;
  • deprecate the existing auxiliary system for cross-crate tests and instead somehow package the crate together with subcrates in a subdirectory (that might require a bit more work though)

@nikomatsakis
Copy link
Contributor Author

I want to do something like the latter point for incr. comp. tests, so I might wind up adding support for it, or at least the groundwork.

@alexcrichton
Copy link
Member

@bors: r+ d3e480f

http://i.imgur.com/zIQ92.jpg

@nikomatsakis
Copy link
Contributor Author

@bors r=alexcrichton

@bors
Copy link
Contributor

bors commented Feb 18, 2016

📌 Commit d3e480f has been approved by alexcrichton

@sanxiyn
Copy link
Member

sanxiyn commented Feb 19, 2016

Sorry to grumble here, but now I can't avoid feeling #20796 was unjustly closed.

@pnkfelix
Copy link
Member

@sanxiyn fixed!

(I am kidding; I do understand your underlying message here. But, to be fair, these things happen, I don't think amy ill will was meant, and a closed issue with no comments beyond the description does not represent a huge amount of lost effort, at least compared to say if that had been a PR of yours that had been closed, right?)

@bors
Copy link
Contributor

bors commented Feb 20, 2016

⌛ Testing commit d3e480f with merge 8caf5be...

@bors
Copy link
Contributor

bors commented Feb 20, 2016

💔 Test failed - auto-win-gnu-64-nopt-t

@steveklabnik
Copy link
Member

These errors seem very odd:

C:/bot/slave/auto-win-gnu-64-nopt-t/build/src/test/compile-fail/borrowck\borrowck-while-cond.rs:13:11: 13:12 error: use of possibly uninitialized variable: `x` [E0381]
C:/bot/slave/auto-win-gnu-64-nopt-t/build/src/test/compile-fail/borrowck\borrowck-while-cond.rs:13     while x { } //~ ERROR use of possibly uninitialized variable: `x`
                                                                                                             ^
C:/bot/slave/auto-win-gnu-64-nopt-t/build/src/test/compile-fail/borrowck\borrowck-while-cond.rs:13:11: 13:12 help: run `rustc --explain E0381` to see a detailed explanation
error: aborting due to previous error

It's right there that it's supposed to be checking for that exact error.

@nikomatsakis
Copy link
Contributor Author

@steveklabnik it must be breaking because of the \ messing up a regex or something...

@nikomatsakis
Copy link
Contributor Author

@bors r+

@bors
Copy link
Contributor

bors commented Feb 24, 2016

📌 Commit c4b6037 has been approved by nikomatsakis

around a set of paths called `TestPaths`

This commit is not quite standalone; it basically contains all the
borrowing plumbing bits, the interesting stuff comes in the next commit.
subdirectory contains `compiletest-ignore-dir`, then ignore it.
@bors
Copy link
Contributor

bors commented Feb 25, 2016

⌛ Testing commit c4b6037 with merge 10b3a4e...

bors added a commit that referenced this pull request Feb 25, 2016
You can now group tests into directories like `run-pass/borrowck` or `compile-fail/borrowck`. By default, all `.rs` files within any directory are considered tests: to ignore some directory, create a placeholder file called `compiletest-ignore-dir` (I had to do this for several existing directories).

r? @alexcrichton
cc @brson
@bors
Copy link
Contributor

bors commented Feb 25, 2016

💔 Test failed - auto-win-gnu-32-opt

@nikomatsakis
Copy link
Contributor Author

@bors r=alexcrichton

@bors
Copy link
Contributor

bors commented Feb 25, 2016

📌 Commit 588d5d1 has been approved by alexcrichton

@bors
Copy link
Contributor

bors commented Feb 25, 2016

⌛ Testing commit 588d5d1 with merge df8c7a2...

@Manishearth
Copy link
Member

(rollup)

@Manishearth Manishearth reopened this Feb 25, 2016
@bors
Copy link
Contributor

bors commented Feb 25, 2016

⌛ Testing commit 588d5d1 with merge a084ab3...

@bors
Copy link
Contributor

bors commented Feb 25, 2016

⛄ The build was interrupted to prioritize another pull request.

@bors
Copy link
Contributor

bors commented Feb 25, 2016

💔 Test failed - auto-win-gnu-64-nopt-t

@alexcrichton
Copy link
Member

@bors: retry

On Thu, Feb 25, 2016 at 5:44 AM, bors notifications@github.com wrote:

[image: 💔] Test failed - auto-win-gnu-64-nopt-t
http://buildbot.rust-lang.org/builders/auto-win-gnu-64-nopt-t/builds/3236


Reply to this email directly or view it on GitHub
#31749 (comment).

@nikomatsakis
Copy link
Contributor Author

@alexcrichton I think I have a fix to this problem

@alexcrichton
Copy link
Member

@bors: r-

Maybe I'll stop blindly retrying things one day

@nikomatsakis
Copy link
Contributor Author

@bors r=alexcrichton

@bors
Copy link
Contributor

bors commented Feb 25, 2016

📌 Commit a04b4b6 has been approved by alexcrichton

@nikomatsakis
Copy link
Contributor Author

@bors r-

@nikomatsakis
Copy link
Contributor Author

@bors r=alexcrichton

@bors
Copy link
Contributor

bors commented Feb 25, 2016

📌 Commit d21434c has been approved by alexcrichton

bors added a commit that referenced this pull request Feb 26, 2016
You can now group tests into directories like `run-pass/borrowck` or `compile-fail/borrowck`. By default, all `.rs` files within any directory are considered tests: to ignore some directory, create a placeholder file called `compiletest-ignore-dir` (I had to do this for several existing directories).

r? @alexcrichton
cc @brson
@bors
Copy link
Contributor

bors commented Feb 26, 2016

⌛ Testing commit d21434c with merge 15e9a95...

@bors bors merged commit d21434c into rust-lang:master Feb 26, 2016
@pitdicker
Copy link
Contributor

I think the problem with auto-win-gnu-64-nopt-t is the same I had with #29497.
In run_rustdoc_test there is a remove_dir_all where the result is ignored, directly followed by ensure_dir.
This is currently racy on Windows...

@pitdicker
Copy link
Contributor

Oops, of course not (doctest gives it away). But I have a branch that should remove the race problem with create_dir_all. Time to finish it.

@nikomatsakis nikomatsakis deleted the compiletest-subdir branch March 30, 2016 16:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants