Skip to content

libtest --include-ignored nightly-gating is confusing #65770

@ehuss

Description

@ehuss
Contributor

The libtest --include-ignored flag is intended to be unstable, but it does not present a clear way to use it.

> cargo +nightly test -- --include-ignored
error: The "include-ignored" flag is only accepted on the nightly compiler
error: test failed, to rerun pass '--lib'

Hmm, I'm running on nightly. Only through some sleuthing can one find out that you have to pass -Zunstable-options to make it work:

cargo +nightly test -- --include-ignored -Zunstable-options

There are several issues here (some of which were noted in the original PR):

  • The text "is only accepted on the nightly compiler" should probably say something about -Zunstable-options.
  • The text "is only accepted on the nightly compiler" is wrong, it works on stable, too. And this isn't a compiler.
  • There is no tracking issue for this feature, so there is nowhere to discuss it. Should one be created?
  • The --help text gives no indication that this flag is unstable.
  • Is there any reason not to just stabilize it now?

Activity

added
A-diagnosticsArea: Messages for errors, warnings, and lints
A-libtestArea: `#[test]` / the `test` library
C-bugCategory: This is a bug.
T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.
A-stabilityArea: `#[stable]`, `#[unstable]` etc.
on Oct 24, 2019
added 2 commits that reference this issue on Mar 24, 2020
d214a2e
f8ec23f
gilescope

gilescope commented on Dec 15, 2020

@gilescope
Contributor

I think it's a footgun that cargo test -- --ignored is the only stable option. We should eliminate that footgun by stabilising --include-ignored.

How does one nominate for stabilising something?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-diagnosticsArea: Messages for errors, warnings, and lintsA-libtestArea: `#[test]` / the `test` libraryA-stabilityArea: `#[stable]`, `#[unstable]` etc.C-bugCategory: This is a bug.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      Participants

      @ehuss@gilescope@jonas-schievink

      Issue actions

        libtest --include-ignored nightly-gating is confusing · Issue #65770 · rust-lang/rust