Update --check-cfg tests that had old --cfg warning
This commit is contained in:
parent
f5023e4c76
commit
a5658e6de8
13 changed files with 28 additions and 83 deletions
|
@ -1,5 +1,5 @@
|
|||
warning: unexpected `cfg` condition name: `unknown_key`
|
||||
--> $DIR/exhaustive-names-values.rs:12:7
|
||||
--> $DIR/exhaustive-names-values.rs:11:7
|
||||
|
|
||||
LL | #[cfg(unknown_key = "value")]
|
||||
| ^^^^^^^^^^^^^^^^^^^^^
|
||||
|
@ -8,7 +8,7 @@ LL | #[cfg(unknown_key = "value")]
|
|||
= note: `#[warn(unexpected_cfgs)]` on by default
|
||||
|
||||
warning: unexpected `cfg` condition value: `value`
|
||||
--> $DIR/exhaustive-names-values.rs:16:7
|
||||
--> $DIR/exhaustive-names-values.rs:15:7
|
||||
|
|
||||
LL | #[cfg(test = "value")]
|
||||
| ^^^^----------
|
||||
|
@ -17,9 +17,5 @@ LL | #[cfg(test = "value")]
|
|||
|
|
||||
= note: no expected value for `test`
|
||||
|
||||
warning: unexpected `empty_cfg` as condition name
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected names
|
||||
|
||||
warning: 3 warnings emitted
|
||||
warning: 2 warnings emitted
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
warning: unexpected `cfg` condition name: `unknown_key`
|
||||
--> $DIR/exhaustive-names-values.rs:12:7
|
||||
--> $DIR/exhaustive-names-values.rs:11:7
|
||||
|
|
||||
LL | #[cfg(unknown_key = "value")]
|
||||
| ^^^^^^^^^^^^^^^^^^^^^
|
||||
|
@ -8,7 +8,7 @@ LL | #[cfg(unknown_key = "value")]
|
|||
= note: `#[warn(unexpected_cfgs)]` on by default
|
||||
|
||||
warning: unexpected `cfg` condition value: `value`
|
||||
--> $DIR/exhaustive-names-values.rs:16:7
|
||||
--> $DIR/exhaustive-names-values.rs:15:7
|
||||
|
|
||||
LL | #[cfg(test = "value")]
|
||||
| ^^^^----------
|
||||
|
@ -17,9 +17,5 @@ LL | #[cfg(test = "value")]
|
|||
|
|
||||
= note: no expected value for `test`
|
||||
|
||||
warning: unexpected `empty_names_values` as condition name
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected names
|
||||
|
||||
warning: 3 warnings emitted
|
||||
warning: 2 warnings emitted
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
warning: unexpected `cfg` condition name: `unknown_key`
|
||||
--> $DIR/exhaustive-names-values.rs:12:7
|
||||
--> $DIR/exhaustive-names-values.rs:11:7
|
||||
|
|
||||
LL | #[cfg(unknown_key = "value")]
|
||||
| ^^^^^^^^^^^^^^^^^^^^^
|
||||
|
@ -8,7 +8,7 @@ LL | #[cfg(unknown_key = "value")]
|
|||
= note: `#[warn(unexpected_cfgs)]` on by default
|
||||
|
||||
warning: unexpected `cfg` condition value: `value`
|
||||
--> $DIR/exhaustive-names-values.rs:16:7
|
||||
--> $DIR/exhaustive-names-values.rs:15:7
|
||||
|
|
||||
LL | #[cfg(test = "value")]
|
||||
| ^^^^----------
|
||||
|
@ -18,16 +18,12 @@ LL | #[cfg(test = "value")]
|
|||
= note: no expected value for `test`
|
||||
|
||||
warning: unexpected `cfg` condition value: `unk`
|
||||
--> $DIR/exhaustive-names-values.rs:20:7
|
||||
--> $DIR/exhaustive-names-values.rs:19:7
|
||||
|
|
||||
LL | #[cfg(feature = "unk")]
|
||||
| ^^^^^^^^^^^^^^^
|
||||
|
|
||||
= note: expected values for `feature` are: `std`
|
||||
|
||||
warning: unexpected condition value `` for condition name `feature`
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected values
|
||||
|
||||
warning: 4 warnings emitted
|
||||
warning: 3 warnings emitted
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
warning: unexpected `cfg` condition name: `unknown_key`
|
||||
--> $DIR/exhaustive-names-values.rs:12:7
|
||||
--> $DIR/exhaustive-names-values.rs:11:7
|
||||
|
|
||||
LL | #[cfg(unknown_key = "value")]
|
||||
| ^^^^^^^^^^^^^^^^^^^^^
|
||||
|
@ -8,7 +8,7 @@ LL | #[cfg(unknown_key = "value")]
|
|||
= note: `#[warn(unexpected_cfgs)]` on by default
|
||||
|
||||
warning: unexpected `cfg` condition value: `value`
|
||||
--> $DIR/exhaustive-names-values.rs:16:7
|
||||
--> $DIR/exhaustive-names-values.rs:15:7
|
||||
|
|
||||
LL | #[cfg(test = "value")]
|
||||
| ^^^^----------
|
||||
|
@ -18,16 +18,12 @@ LL | #[cfg(test = "value")]
|
|||
= note: no expected value for `test`
|
||||
|
||||
warning: unexpected `cfg` condition value: `unk`
|
||||
--> $DIR/exhaustive-names-values.rs:20:7
|
||||
--> $DIR/exhaustive-names-values.rs:19:7
|
||||
|
|
||||
LL | #[cfg(feature = "unk")]
|
||||
| ^^^^^^^^^^^^^^^
|
||||
|
|
||||
= note: expected values for `feature` are: `std`
|
||||
|
||||
warning: unexpected `full` as condition name
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected names
|
||||
|
||||
warning: 4 warnings emitted
|
||||
warning: 3 warnings emitted
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
// Check warning for unexpected cfg in the code and in the CLI
|
||||
// arguments (here the revision cfg).
|
||||
// Check warning for unexpected cfg in the code.
|
||||
//
|
||||
// check-pass
|
||||
// revisions: empty_names_values empty_cfg feature full
|
||||
|
|
|
@ -7,9 +7,5 @@ LL | #[cfg(unknown_key = "value")]
|
|||
= help: expected names are: `debug_assertions`, `doc`, `doctest`, `feature`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `sanitize`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `unix`, `windows`
|
||||
= note: `#[warn(unexpected_cfgs)]` on by default
|
||||
|
||||
warning: unexpected `empty_names` as condition name
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected names
|
||||
|
||||
warning: 2 warnings emitted
|
||||
warning: 1 warning emitted
|
||||
|
||||
|
|
|
@ -7,9 +7,5 @@ LL | #[cfg(unknown_key = "value")]
|
|||
= help: expected names are: `debug_assertions`, `doc`, `doctest`, `feature`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `sanitize`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `unix`, `windows`
|
||||
= note: `#[warn(unexpected_cfgs)]` on by default
|
||||
|
||||
warning: unexpected `exhaustive_names` as condition name
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected names
|
||||
|
||||
warning: 2 warnings emitted
|
||||
warning: 1 warning emitted
|
||||
|
||||
|
|
|
@ -9,9 +9,5 @@ LL | #[cfg(test = "value")]
|
|||
= note: no expected value for `test`
|
||||
= note: `#[warn(unexpected_cfgs)]` on by default
|
||||
|
||||
warning: unexpected `empty_cfg` as condition name
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected names
|
||||
|
||||
warning: 2 warnings emitted
|
||||
warning: 1 warning emitted
|
||||
|
||||
|
|
|
@ -38,14 +38,6 @@ LL | #[cfg_attr(uu, test)]
|
|||
|
|
||||
= help: expected names are: `cfg`, `debug_assertions`, `doc`, `doctest`, `feature`, `miri`, `names_values`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `sanitize`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `unix`, `windows`
|
||||
|
||||
warning: unexpected condition value `bar` for condition name `feature`
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected values
|
||||
|
||||
warning: unexpected `unknown_name` as condition name
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected names
|
||||
|
||||
warning: unexpected `cfg` condition name: `widnows`
|
||||
--> $DIR/mix.rs:43:10
|
||||
|
|
||||
|
@ -188,5 +180,5 @@ LL | cfg!(all(feature = "zebra", feature = "zebra", feature = "zebra"));
|
|||
|
|
||||
= note: expected values for `feature` are: `foo`
|
||||
|
||||
warning: 28 warnings emitted
|
||||
warning: 26 warnings emitted
|
||||
|
||||
|
|
|
@ -38,14 +38,6 @@ LL | #[cfg_attr(uu, test)]
|
|||
|
|
||||
= help: expected names are: `cfg`, `debug_assertions`, `doc`, `doctest`, `feature`, `miri`, `names_values`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `sanitize`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `unix`, `windows`
|
||||
|
||||
warning: unexpected condition value `bar` for condition name `feature`
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected values
|
||||
|
||||
warning: unexpected `unknown_name` as condition name
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected names
|
||||
|
||||
warning: unexpected `cfg` condition name: `widnows`
|
||||
--> $DIR/mix.rs:43:10
|
||||
|
|
||||
|
@ -188,5 +180,5 @@ LL | cfg!(all(feature = "zebra", feature = "zebra", feature = "zebra"));
|
|||
|
|
||||
= note: expected values for `feature` are: `foo`
|
||||
|
||||
warning: 28 warnings emitted
|
||||
warning: 26 warnings emitted
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
warning: unexpected `cfg` condition value: `sedre`
|
||||
--> $DIR/unexpected-cfg-value.rs:11:7
|
||||
--> $DIR/unexpected-cfg-value.rs:9:7
|
||||
|
|
||||
LL | #[cfg(feature = "sedre")]
|
||||
| ^^^^^^^^^^-------
|
||||
|
@ -10,16 +10,12 @@ LL | #[cfg(feature = "sedre")]
|
|||
= note: `#[warn(unexpected_cfgs)]` on by default
|
||||
|
||||
warning: unexpected `cfg` condition value: `rand`
|
||||
--> $DIR/unexpected-cfg-value.rs:18:7
|
||||
--> $DIR/unexpected-cfg-value.rs:16:7
|
||||
|
|
||||
LL | #[cfg(feature = "rand")]
|
||||
| ^^^^^^^^^^^^^^^^
|
||||
|
|
||||
= note: expected values for `feature` are: `full`, `serde`
|
||||
|
||||
warning: unexpected condition value `rand` for condition name `feature`
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected values
|
||||
|
||||
warning: 3 warnings emitted
|
||||
warning: 2 warnings emitted
|
||||
|
||||
|
|
|
@ -1,10 +1,8 @@
|
|||
// Check warning for invalid configuration value in the code and
|
||||
// in the cli
|
||||
// Check for unexpected configuration value in the code.
|
||||
//
|
||||
// check-pass
|
||||
// revisions: values cfg
|
||||
// compile-flags: --cfg=feature="rand" -Z unstable-options
|
||||
// compile-flags: --check-cfg=cfg(values,cfg)
|
||||
// compile-flags: -Z unstable-options
|
||||
// [values]compile-flags: --check-cfg=values(feature,"serde","full")
|
||||
// [cfg]compile-flags: --check-cfg=cfg(feature,values("serde","full"))
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
warning: unexpected `cfg` condition value: `sedre`
|
||||
--> $DIR/unexpected-cfg-value.rs:11:7
|
||||
--> $DIR/unexpected-cfg-value.rs:9:7
|
||||
|
|
||||
LL | #[cfg(feature = "sedre")]
|
||||
| ^^^^^^^^^^-------
|
||||
|
@ -10,16 +10,12 @@ LL | #[cfg(feature = "sedre")]
|
|||
= note: `#[warn(unexpected_cfgs)]` on by default
|
||||
|
||||
warning: unexpected `cfg` condition value: `rand`
|
||||
--> $DIR/unexpected-cfg-value.rs:18:7
|
||||
--> $DIR/unexpected-cfg-value.rs:16:7
|
||||
|
|
||||
LL | #[cfg(feature = "rand")]
|
||||
| ^^^^^^^^^^^^^^^^
|
||||
|
|
||||
= note: expected values for `feature` are: `full`, `serde`
|
||||
|
||||
warning: unexpected condition value `rand` for condition name `feature`
|
||||
|
|
||||
= help: was set with `--cfg` but isn't in the `--check-cfg` expected values
|
||||
|
||||
warning: 3 warnings emitted
|
||||
warning: 2 warnings emitted
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue