]> git.lizzy.rs Git - rust.git/commitdiff
Remove unsupported test features from compiletest.
authorAhmed Charles <acharles@outlook.com>
Mon, 19 Jan 2015 08:20:31 +0000 (00:20 -0800)
committerAhmed Charles <acharles@outlook.com>
Tue, 20 Jan 2015 07:40:27 +0000 (23:40 -0800)
Removes test-shard, ratchet-metrics and save-metrics from Config in
compiletest/common.rs.

src/compiletest/common.rs
src/compiletest/compiletest.rs

index c29f74d74181087ab05ef8f6f6e79af20fdc6670..1058a489037568c6bc5aad6e6e3794bed08f56be 100644 (file)
@@ -115,20 +115,6 @@ pub struct Config {
     // Write out a parseable log of tests that were run
     pub logfile: Option<Path>,
 
-    // Write out a json file containing any metrics of the run
-    pub save_metrics: Option<Path>,
-
-    // Write and ratchet a metrics file
-    pub ratchet_metrics: Option<Path>,
-
-    // Percent change in metrics to consider noise
-    pub ratchet_noise_percent: Option<f64>,
-
-    // "Shard" of the testsuite to pub run: this has the form of
-    // two numbers (a,b), and causes only those tests with
-    // positional order equal to a mod b to run.
-    pub test_shard: Option<(uint,uint)>,
-
     // A command line to prefix program execution with,
     // for running under valgrind
     pub runtool: Option<String>,
index f3514c6e7bc8264e71799fa8a22129bcdcee5682..17a39bc1c74d4af2c32ab94675e8751e81579b47 100644 (file)
@@ -77,10 +77,6 @@ pub fn parse_config(args: Vec<String> ) -> Config {
           optopt("", "target-rustcflags", "flags to pass to rustc for target", "FLAGS"),
           optflag("", "verbose", "run tests verbosely, showing all output"),
           optopt("", "logfile", "file to log test execution to", "FILE"),
-          optopt("", "save-metrics", "file to save metrics to", "FILE"),
-          optopt("", "ratchet-metrics", "file to ratchet metrics against", "FILE"),
-          optopt("", "ratchet-noise-percent",
-                 "percent change in metrics to consider noise", "N"),
           optflag("", "jit", "run tests under the JIT"),
           optopt("", "target", "the target to build for", "TARGET"),
           optopt("", "host", "the host to build for", "HOST"),
@@ -90,7 +86,6 @@ pub fn parse_config(args: Vec<String> ) -> Config {
           optopt("", "adb-path", "path to the android debugger", "PATH"),
           optopt("", "adb-test-dir", "path to tests for the android debugger", "PATH"),
           optopt("", "lldb-python-dir", "directory containing LLDB's python module", "PATH"),
-          optopt("", "test-shard", "run shard A, of B shards, worth of the testsuite", "A.B"),
           optflag("h", "help", "show this message"));
 
     assert!(!args.is_empty());
@@ -152,12 +147,6 @@ fn opt_path(m: &getopts::Matches, nm: &str) -> Path {
         filter: filter,
         cfail_regex: Regex::new(errors::EXPECTED_PATTERN).unwrap(),
         logfile: matches.opt_str("logfile").map(|s| Path::new(s)),
-        save_metrics: matches.opt_str("save-metrics").map(|s| Path::new(s)),
-        ratchet_metrics:
-            matches.opt_str("ratchet-metrics").map(|s| Path::new(s)),
-        ratchet_noise_percent:
-            matches.opt_str("ratchet-noise-percent")
-                   .and_then(|s| s.as_slice().parse::<f64>()),
         runtool: matches.opt_str("runtool"),
         host_rustcflags: matches.opt_str("host-rustcflags"),
         target_rustcflags: matches.opt_str("target-rustcflags"),
@@ -176,7 +165,6 @@ fn opt_path(m: &getopts::Matches, nm: &str) -> Path {
                 opt_str2(matches.opt_str("adb-test-dir")).as_slice() &&
             !opt_str2(matches.opt_str("adb-test-dir")).is_empty(),
         lldb_python_dir: matches.opt_str("lldb-python-dir"),
-        test_shard: test::opt_shard(matches.opt_str("test-shard")),
         verbose: matches.opt_present("verbose"),
     }
 }
@@ -210,10 +198,6 @@ pub fn log_config(config: &Config) {
     logv(c, format!("adb_test_dir: {:?}", config.adb_test_dir));
     logv(c, format!("adb_device_status: {}",
                     config.adb_device_status));
-    match config.test_shard {
-        None => logv(c, "test_shard: (all)".to_string()),
-        Some((a,b)) => logv(c, format!("test_shard: {}.{}", a, b))
-    }
     logv(c, format!("verbose: {}", config.verbose));
     logv(c, format!("\n"));
 }
@@ -284,10 +268,10 @@ pub fn test_opts(config: &Config) -> test::TestOpts {
         logfile: config.logfile.clone(),
         run_tests: true,
         run_benchmarks: true,
-        ratchet_metrics: config.ratchet_metrics.clone(),
-        ratchet_noise_percent: config.ratchet_noise_percent.clone(),
-        save_metrics: config.save_metrics.clone(),
-        test_shard: config.test_shard.clone(),
+        ratchet_metrics: None,
+        ratchet_noise_percent: None,
+        save_metrics: None,
+        test_shard: None,
         nocapture: false,
         color: test::AutoColor,
         show_boxplot: false,