diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2025-07-21 14:34:12 +0200 |
|---|---|---|
| committer | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2025-07-22 14:28:48 +0200 |
| commit | a27f3e3fd1e4d16160f8885b6b06665b5319f56c (patch) | |
| tree | b033935392cbadf6f85d2dbddf433a88e323aeeb /tests/codegen-llvm/meta-filecheck | |
| parent | ed93c1783b404d728d4809973a0550eb33cd293f (diff) | |
| download | rust-a27f3e3fd1e4d16160f8885b6b06665b5319f56c.tar.gz rust-a27f3e3fd1e4d16160f8885b6b06665b5319f56c.zip | |
Rename `tests/codegen` into `tests/codegen-llvm`
Diffstat (limited to 'tests/codegen-llvm/meta-filecheck')
5 files changed, 32 insertions, 0 deletions
diff --git a/tests/codegen-llvm/meta-filecheck/check-prefix.rs b/tests/codegen-llvm/meta-filecheck/check-prefix.rs new file mode 100644 index 00000000000..98bec68627e --- /dev/null +++ b/tests/codegen-llvm/meta-filecheck/check-prefix.rs @@ -0,0 +1,4 @@ +// Simple test that uses the default CHECK prefix and should always succeed. + +// CHECK: main +fn main() {} diff --git a/tests/codegen-llvm/meta-filecheck/filecheck-flags.rs b/tests/codegen-llvm/meta-filecheck/filecheck-flags.rs new file mode 100644 index 00000000000..8e451cf4fdc --- /dev/null +++ b/tests/codegen-llvm/meta-filecheck/filecheck-flags.rs @@ -0,0 +1,8 @@ +// Arguments provided via `filecheck-flags` should be passed to `filecheck`. + +//@ revisions: good bad +//@ [good] filecheck-flags: --check-prefix=CUSTOM +//@ [bad] should-fail + +// CUSTOM: main +fn main() {} diff --git a/tests/codegen-llvm/meta-filecheck/msvc-prefix-bad.rs b/tests/codegen-llvm/meta-filecheck/msvc-prefix-bad.rs new file mode 100644 index 00000000000..f9984c74e2a --- /dev/null +++ b/tests/codegen-llvm/meta-filecheck/msvc-prefix-bad.rs @@ -0,0 +1,7 @@ +// This is exactly like `msvc-prefix-good.rs`, except that it should always fail. + +//@ should-fail + +// MSVC: text that should not match +// NONMSVC: text that should not match +fn main() {} diff --git a/tests/codegen-llvm/meta-filecheck/no-directives.rs b/tests/codegen-llvm/meta-filecheck/no-directives.rs new file mode 100644 index 00000000000..2cab263604e --- /dev/null +++ b/tests/codegen-llvm/meta-filecheck/no-directives.rs @@ -0,0 +1,5 @@ +// A test that doesn't include any filecheck directives should fail. + +//@ should-fail + +fn main() {} diff --git a/tests/codegen-llvm/meta-filecheck/revision-prefix.rs b/tests/codegen-llvm/meta-filecheck/revision-prefix.rs new file mode 100644 index 00000000000..431066e3acc --- /dev/null +++ b/tests/codegen-llvm/meta-filecheck/revision-prefix.rs @@ -0,0 +1,8 @@ +// The current revision name is registered as a filecheck prefix. + +//@ revisions: GOOD BAD +//@ [BAD] should-fail + +// GOOD: main +// BAD: text that should not match +fn main() {} |
