Add a test for unit test of proc-macro
crate
This commit is contained in:
parent
ecab8a4fae
commit
28577924e7
@ -102,7 +102,7 @@ def test_cargo_miri_test():
|
||||
)
|
||||
test("`cargo miri test` (subcrate, no isolation)",
|
||||
cargo_miri("test") + ["-p", "subcrate"],
|
||||
"test.subcrate.stdout.ref", "test.stderr-empty.ref",
|
||||
"test.subcrate.stdout.ref", "test.stderr-proc-macro.ref",
|
||||
env={'MIRIFLAGS': "-Zmiri-disable-isolation"},
|
||||
)
|
||||
|
||||
|
@ -4,6 +4,10 @@ version = "0.1.0"
|
||||
authors = ["Miri Team"]
|
||||
edition = "2018"
|
||||
|
||||
[lib]
|
||||
proc-macro = true
|
||||
doctest = false
|
||||
|
||||
[[bin]]
|
||||
name = "subcrate"
|
||||
path = "main.rs"
|
||||
|
2
test-cargo-miri/subcrate/src/lib.rs
Normal file
2
test-cargo-miri/subcrate/src/lib.rs
Normal file
@ -0,0 +1,2 @@
|
||||
#[cfg(test)]
|
||||
compile_error!("Miri should not touch me");
|
1
test-cargo-miri/test.stderr-proc-macro.ref
Normal file
1
test-cargo-miri/test.stderr-proc-macro.ref
Normal file
@ -0,0 +1 @@
|
||||
Running unit tests of `proc-macro` crates is not currently supported by Miri.
|
Loading…
Reference in New Issue
Block a user