Upgrade to rustc ba2f13ef0 2015-02-04

This commit is contained in:
Simon Sapin 2015-01-31 14:36:05 +01:00 committed by Matt Brubeck
parent bc6882bdef
commit d5dd1d658e
136 changed files with 1091 additions and 878 deletions

View file

@ -8,23 +8,22 @@
// except according to those terms.
extern crate getopts;
extern crate regex;
extern crate test;
use test::{AutoColor, TestOpts, run_tests_console, TestDesc, TestDescAndFn, DynTestFn, DynTestName};
use test::ShouldFail;
use getopts::{getopts, reqopt};
use std::{os, str};
use std::io::fs;
use std::io::Reader;
use std::io::process::{Command, Ignored, CreatePipe, InheritFd, ExitStatus};
use std::old_io::fs;
use std::old_io::Reader;
use std::old_io::process::{Command, Ignored, CreatePipe, InheritFd, ExitStatus};
use std::old_path::Path;
use std::thunk::Thunk;
use regex::Regex;
#[derive(Clone)]
struct Config {
source_dir: String,
filter: Option<Regex>
filter: Option<String>
}
fn main() {
@ -49,7 +48,7 @@ fn parse_config(args: Vec<String>) -> Config {
Config {
source_dir: matches.opt_str("source-dir").unwrap(),
filter: matches.free.as_slice().first().map(|&:s| Regex::new(s.as_slice()).unwrap())
filter: matches.free.first().map(|s| s.clone())
}
}
@ -59,16 +58,9 @@ fn test_options(config: Config) -> TestOpts {
run_ignored: false,
run_tests: true,
run_benchmarks: false,
ratchet_metrics: None,
ratchet_noise_percent: None,
save_metrics: None,
test_shard: None,
logfile: None,
nocapture: false,
color: AutoColor,
show_boxplot: false,
boxplot_width: 0,
show_all_stats: false,
}
}
@ -89,7 +81,7 @@ fn make_test(file: String) -> TestDescAndFn {
ignore: false,
should_fail: ShouldFail::No,
},
testfn: DynTestFn(Thunk::new(move |:| { run_test(file) }))
testfn: DynTestFn(Thunk::new(move || { run_test(file) }))
}
}

View file

@ -7,22 +7,21 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#[macro_use] extern crate bitflags;
extern crate png;
extern crate test;
extern crate regex;
extern crate url;
use std::ascii::AsciiExt;
use std::io;
use std::io::{File, Reader, Command, IoResult};
use std::io::process::ExitStatus;
use std::io::fs::PathExtensions;
use std::old_io as io;
use std::old_io::{File, Reader, Command, IoResult};
use std::old_io::process::ExitStatus;
use std::old_io::fs::PathExtensions;
use std::old_path::Path;
use std::os;
use std::path::Path;
use std::thunk::Thunk;
use test::{AutoColor, DynTestName, DynTestFn, TestDesc, TestOpts, TestDescAndFn, ShouldFail};
use test::run_tests_console;
use regex::Regex;
use url::Url;
@ -47,7 +46,7 @@ fn main() {
let (render_mode_string, base_path, testname) = match harness_args {
[] | [_] => panic!("USAGE: cpu|gpu base_path [testname regex]"),
[ref render_mode_string, ref base_path] => (render_mode_string, base_path, None),
[ref render_mode_string, ref base_path, ref testname, ..] => (render_mode_string, base_path, Some(Regex::new(testname.as_slice()).unwrap())),
[ref render_mode_string, ref base_path, ref testname, ..] => (render_mode_string, base_path, Some(testname.clone())),
};
let mut render_mode = match render_mode_string.as_slice() {
@ -88,15 +87,8 @@ fn main() {
logfile: None,
run_tests: true,
run_benchmarks: false,
ratchet_noise_percent: None,
ratchet_metrics: None,
save_metrics: None,
test_shard: None,
nocapture: false,
color: AutoColor,
show_boxplot: false,
boxplot_width: 0,
show_all_stats: false,
};
match run(test_opts,

View file

@ -3,3 +3,4 @@
expected: OK
[XMLHttpRequest: open() resolving URLs (multi-Window; 2; evil)]
expected: FAIL

View file

@ -3,3 +3,4 @@
expected: OK
[XMLHttpRequest: open() resolving URLs (multi-Window; 3; evil)]
expected: FAIL

View file

@ -1,5 +0,0 @@
[send-accept.htm]
type: testharness
[XMLHttpRequest: send() - Accept]
expected: FAIL

View file

@ -6,3 +6,4 @@
[The SecurityError must be thrown if the container\'s document does not have the same effective script origin]
expected: FAIL

View file

@ -96,9 +96,6 @@
[<picture></picture><svg></svg><source srcset="data:,b"><img src="data:,a" data-expect="data:,b">]
expected: FAIL
[<picture></picture><svg></svg><font></font><source srcset="data:,b"><img src="data:,a" data-expect="data:,a">]
expected: FAIL
[<picture></picture><svg></svg><!--<font face> tag breaks out of svg--><font face=""></font><source srcset="data:,b"><img src="data:,a" data-expect="data:,b">]
expected: FAIL
@ -264,3 +261,6 @@
[<picture></picture><source srcset="data:,b"><img data-expect="data:,b">]
expected: FAIL
[<picture></picture><svg></svg><font></font><source srcset="data:,b"><font></font><img src="data:,a" data-expect="data:,a">]
expected: FAIL