about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2013-07-04 14:58:02 -0700
committerAlex Crichton <alex@alexcrichton.com>2013-07-07 19:03:57 -0700
commita02e37c397211c09467f374a60597efa1a57ea07 (patch)
tree3c9c1eb97c0638f5bfc2e84a263d1e08419973e4
parentddf8247d7f1864372e3e74ee2374a2a257569c7c (diff)
downloadrust-a02e37c397211c09467f374a60597efa1a57ea07.tar.gz
rust-a02e37c397211c09467f374a60597efa1a57ea07.zip
Fix a warning when generating tests
-rw-r--r--src/librustc/front/test.rs4
-rw-r--r--src/test/run-pass/test-ignore-cfg.rs2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/librustc/front/test.rs b/src/librustc/front/test.rs
index f2670a663ea..f4d89f559f2 100644
--- a/src/librustc/front/test.rs
+++ b/src/librustc/front/test.rs
@@ -309,7 +309,7 @@ fn mk_test_module(cx: &TestCtxt) -> @ast::item {
     let mainfn = (quote_item!(
         pub fn main() {
             #[main];
-            extra::test::test_main_static(::std::os::args(), tests);
+            extra::test::test_main_static(::std::os::args(), TESTS);
         }
     )).get();
 
@@ -366,7 +366,7 @@ fn mk_tests(cx: &TestCtxt) -> @ast::item {
     let test_descs = mk_test_descs(cx);
 
     (quote_item!(
-        pub static tests : &'static [self::extra::test::TestDescAndFn] =
+        pub static TESTS : &'static [self::extra::test::TestDescAndFn] =
             $test_descs
         ;
     )).get()
diff --git a/src/test/run-pass/test-ignore-cfg.rs b/src/test/run-pass/test-ignore-cfg.rs
index e7a23244c06..e54bc7404b4 100644
--- a/src/test/run-pass/test-ignore-cfg.rs
+++ b/src/test/run-pass/test-ignore-cfg.rs
@@ -26,7 +26,7 @@ fn shouldnotignore() {
 #[test]
 fn checktests() {
     // Pull the tests out of the secreturn test module
-    let tests = __test::tests;
+    let tests = __test::TESTS;
 
     assert!(
         tests.iter().any_(|t| t.desc.name.to_str() == ~"shouldignore" && t.desc.ignore));