Skip to content

compiletest: error-pattern and warnings are not checked in run-pass tests #35165

Closed
@michaelwoerister

Description

@michaelwoerister

There are some run-pass tests that seemingly check whether a specific warning or error is emitted. As far as I can tell though, the compiletest tool just ignores the given directives in a run-pass test case, i.e. changing the given directives to something unexpected still lets the tests pass.

Some affected test cases (in no particular order):

  • attr-before-view-item.rs
  • attr-before-view-item2.rs
  • deprecated-macro_escape-inner.rs
  • deprecated-macro_escape.rs
  • deriving-meta-empty-trait-list.rs
  • liveness-assign-imm-local-after-ret.rs
  • unreachable-code-1.rs
  • auxiliary/const_fn_lib.rs
  • auxiliary/issue_3136_a.rs
  • enum-size-variance.rs
  • issue-25757.rs
  • pred-not-bool.rs
  • issue-19100.rs
  • issue-2611-3.rs

cc @rust-lang/compiler @rust-lang/tools

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-testsuiteArea: The testsuite used to check the correctness of rustcE-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions