fix test imports for latest nightly (#355)

This commit is contained in:
Michael Stewart 2019-03-22 21:18:55 -07:00 committed by 강동윤
parent 84973890e7
commit 6f97012821
6 changed files with 12 additions and 12 deletions

View File

@ -18,7 +18,7 @@ use std::{
use swc_common::comments::Comments; use swc_common::comments::Comments;
use swc_ecma_codegen::Emitter; use swc_ecma_codegen::Emitter;
use swc_ecma_parser::{Parser, Session, SourceFileInput, Syntax}; use swc_ecma_parser::{Parser, Session, SourceFileInput, Syntax};
use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, TestFn, TestName}; use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, DynTestFn, TestName};
use testing::NormalizedOutput; use testing::NormalizedOutput;
const IGNORED_PASS_TESTS: &[&str] = &[ const IGNORED_PASS_TESTS: &[&str] = &[
@ -83,7 +83,7 @@ fn add_test<F: FnOnce() + Send + 'static>(
should_panic: No, should_panic: No,
allow_fail: false, allow_fail: false,
}, },
testfn: TestFn::DynTestFn(box f), testfn: DynTestFn(box f),
}); });
} }

View File

@ -10,7 +10,7 @@ extern crate walkdir;
use self::{ use self::{
parser::{SourceFileInput, Syntax}, parser::{SourceFileInput, Syntax},
test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, TestFn, TestName}, test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, DynTestFn, TestName},
}; };
use std::{ use std::{
env, env,
@ -34,7 +34,7 @@ fn add_test<F: FnOnce() + Send + 'static>(
should_panic: No, should_panic: No,
allow_fail: false, allow_fail: false,
}, },
testfn: TestFn::DynTestFn(box f), testfn: DynTestFn(box f),
}); });
} }

View File

@ -23,7 +23,7 @@ use std::{
use swc_common::{errors::Handler, Fold, FoldWith, SourceMap}; use swc_common::{errors::Handler, Fold, FoldWith, SourceMap};
use swc_ecma_ast::*; use swc_ecma_ast::*;
use swc_ecma_parser::{PResult, Parser, Session, SourceFileInput}; use swc_ecma_parser::{PResult, Parser, Session, SourceFileInput};
use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, TestFn, TestName}; use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, DynTestFn, TestName};
use testing::{run_test, StdErr}; use testing::{run_test, StdErr};
use walkdir::WalkDir; use walkdir::WalkDir;
@ -40,7 +40,7 @@ fn add_test<F: FnOnce() + Send + 'static>(
should_panic: No, should_panic: No,
allow_fail: false, allow_fail: false,
}, },
testfn: TestFn::DynTestFn(box f), testfn: DynTestFn(box f),
}); });
} }

View File

@ -17,7 +17,7 @@ use std::{
use swc_common::{Fold, FoldWith, Span}; use swc_common::{Fold, FoldWith, Span};
use swc_ecma_ast::*; use swc_ecma_ast::*;
use swc_ecma_parser::{PResult, Parser, Session, SourceFileInput, Syntax}; use swc_ecma_parser::{PResult, Parser, Session, SourceFileInput, Syntax};
use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, TestFn, TestName}; use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, DynTestFn, TestName};
use testing::{NormalizedOutput, StdErr}; use testing::{NormalizedOutput, StdErr};
const IGNORED_PASS_TESTS: &[&str] = &[ const IGNORED_PASS_TESTS: &[&str] = &[
@ -82,7 +82,7 @@ fn add_test<F: FnOnce() + Send + 'static>(
should_panic: No, should_panic: No,
allow_fail: false, allow_fail: false,
}, },
testfn: TestFn::DynTestFn(box f), testfn: DynTestFn(box f),
}); });
} }

View File

@ -21,7 +21,7 @@ use std::{
use swc_common::{Fold, FoldWith}; use swc_common::{Fold, FoldWith};
use swc_ecma_ast::*; use swc_ecma_ast::*;
use swc_ecma_parser::{PResult, Parser, Session, SourceFileInput, Syntax, TsConfig}; use swc_ecma_parser::{PResult, Parser, Session, SourceFileInput, Syntax, TsConfig};
use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, TestFn, TestName}; use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, DynTestFn, TestName};
use testing::StdErr; use testing::StdErr;
use walkdir::WalkDir; use walkdir::WalkDir;
@ -41,7 +41,7 @@ fn add_test<F: FnOnce() + Send + 'static>(
should_panic: No, should_panic: No,
allow_fail: false, allow_fail: false,
}, },
testfn: TestFn::DynTestFn(box f), testfn: DynTestFn(box f),
}); });
} }

View File

@ -22,7 +22,7 @@ use swc_ecma_ast::*;
use swc_ecma_codegen::Emitter; use swc_ecma_codegen::Emitter;
use swc_ecma_parser::{Parser, Session, SourceFileInput, Syntax}; use swc_ecma_parser::{Parser, Session, SourceFileInput, Syntax};
use swc_ecma_transforms::fixer; use swc_ecma_transforms::fixer;
use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, TestFn, TestName}; use test::{test_main, Options, ShouldPanic::No, TestDesc, TestDescAndFn, DynTestFn, TestName};
const IGNORED_PASS_TESTS: &[&str] = &[ const IGNORED_PASS_TESTS: &[&str] = &[
// TODO: uningnore // TODO: uningnore
@ -105,7 +105,7 @@ fn add_test<F: FnOnce() + Send + 'static>(
should_panic: No, should_panic: No,
allow_fail: false, allow_fail: false,
}, },
testfn: TestFn::DynTestFn(box f), testfn: DynTestFn(box f),
}); });
} }