about summary refs log tree commit diff
diff options
context:
space:
mode:
authorNiko Matsakis <niko@alum.mit.edu>2016-03-02 14:20:55 -0500
committerNiko Matsakis <niko@alum.mit.edu>2016-03-02 14:26:28 -0500
commitad3ed805030a128d83349cbf3c2dfab15c8a61a7 (patch)
tree575c7d40f1cb9b10f3041ac35e762a13d4b5cd21
parent0d6b4e03862065d0b1296e93c9bdfed25e0f60a4 (diff)
downloadrust-ad3ed805030a128d83349cbf3c2dfab15c8a61a7.tar.gz
rust-ad3ed805030a128d83349cbf3c2dfab15c8a61a7.zip
rename should-panic to should-fail, per acrichto's suggestion
-rw-r--r--COMPILER_TESTS.md2
-rw-r--r--src/compiletest/compiletest.rs2
-rw-r--r--src/compiletest/header.rs10
-rw-r--r--src/test/compile-fail/meta-expected-error-wrong-rev.rs2
4 files changed, 8 insertions, 8 deletions
diff --git a/COMPILER_TESTS.md b/COMPILER_TESTS.md
index 9b63fe3fba3..3f91c3eb949 100644
--- a/COMPILER_TESTS.md
+++ b/COMPILER_TESTS.md
@@ -42,7 +42,7 @@ whole, instead of just a few lines inside the test.
 * `ignore-test` always ignores the test
 * `ignore-lldb` and `ignore-gdb` will skip the debuginfo tests
 * `min-{gdb,lldb}-version`
-* `should-panic` indicates that the test should fail; used for "meta testing",
+* `should-fail` indicates that the test should fail; used for "meta testing",
   where we test the compiletest program itself to check that it will generate
   errors in appropriate scenarios
 
diff --git a/src/compiletest/compiletest.rs b/src/compiletest/compiletest.rs
index 755ec2f31dc..1042359d05b 100644
--- a/src/compiletest/compiletest.rs
+++ b/src/compiletest/compiletest.rs
@@ -359,7 +359,7 @@ pub fn make_test(config: &Config, testpaths: &TestPaths) -> test::TestDescAndFn
         desc: test::TestDesc {
             name: make_test_name(config, testpaths),
             ignore: early_props.ignore,
-            should_panic: if early_props.should_panic {
+            should_panic: if early_props.should_fail {
                 test::ShouldPanic::Yes
             } else {
                 test::ShouldPanic::No
diff --git a/src/compiletest/header.rs b/src/compiletest/header.rs
index 6882be44cbc..cf4d545a827 100644
--- a/src/compiletest/header.rs
+++ b/src/compiletest/header.rs
@@ -179,7 +179,7 @@ pub fn load_props_into(props: &mut TestProps, testfile: &Path, cfg: Option<&str>
 
 pub struct EarlyProps {
     pub ignore: bool,
-    pub should_panic: bool,
+    pub should_fail: bool,
 }
 
 // scan the file to detect whether the test should be ignored and
@@ -188,7 +188,7 @@ pub struct EarlyProps {
 pub fn early_props(config: &Config, testfile: &Path) -> EarlyProps {
     let mut props = EarlyProps {
         ignore: false,
-        should_panic: false,
+        should_fail: false,
     };
 
     iter_header(testfile, None, &mut |ln| {
@@ -206,9 +206,9 @@ pub fn early_props(config: &Config, testfile: &Path) -> EarlyProps {
             ignore_gdb(config, ln) ||
             ignore_lldb(config, ln);
 
-        props.should_panic =
-            props.should_panic ||
-            parse_name_directive(ln, "should-panic");
+        props.should_fail =
+            props.should_fail ||
+            parse_name_directive(ln, "should-fail");
     });
 
     return props;
diff --git a/src/test/compile-fail/meta-expected-error-wrong-rev.rs b/src/test/compile-fail/meta-expected-error-wrong-rev.rs
index 83e0702af62..084c6ed4f4b 100644
--- a/src/test/compile-fail/meta-expected-error-wrong-rev.rs
+++ b/src/test/compile-fail/meta-expected-error-wrong-rev.rs
@@ -9,7 +9,7 @@
 // except according to those terms.
 
 // revisions: a
-// should-panic
+// should-fail
 // pretty-expanded FIXME #23616
 
 // This is a "meta-test" of the compilertest framework itself.  In