Skip to content

Commit

Permalink
Fix fallout in tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
jseyfried committed Aug 25, 2016
1 parent bfb01bb commit 469753f
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
8 changes: 6 additions & 2 deletions src/librustc/session/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1772,7 +1772,9 @@ mod tests {
use std::path::PathBuf;
use std::rc::Rc;
use super::{OutputType, OutputTypes, Externs, PanicStrategy};
use syntax::attr;
use syntax::{ast, attr};
use syntax::parse::token::InternedString;
use syntax::codemap::dummy_spanned;

fn optgroups() -> Vec<OptGroup> {
super::rustc_optgroups().into_iter()
Expand Down Expand Up @@ -1801,7 +1803,9 @@ mod tests {
let (sessopts, cfg) = build_session_options_and_crate_config(matches);
let sess = build_session(sessopts, &dep_graph, None, registry, Rc::new(DummyCrateStore));
let cfg = build_configuration(&sess, cfg);
assert!((attr::contains_name(&cfg[..], "test")));
assert!(attr::contains(&cfg, &dummy_spanned(ast::MetaItemKind::Word({
InternedString::new("test")
}))));
}

// When the user supplies --test and --cfg test, don't implicitly add
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ extern crate rustc;
extern crate rustc_plugin;

use syntax::ast::{self, Item, MetaItem, ItemKind};
use syntax::attr::{AttrMetaMethods, AttrNestedMetaItemMethods};
use syntax::ext::base::*;
use syntax::parse::{self, token};
use syntax::ptr::P;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ extern crate rustc;
extern crate rustc_plugin;

use syntax::ast;
use syntax::attr::AttrMetaMethods;
use syntax::ext::base::{MultiDecorator, ExtCtxt, Annotatable};
use syntax::ext::build::AstBuilder;
use syntax::parse::token;
Expand Down
1 change: 0 additions & 1 deletion src/test/run-pass-fulldeps/auxiliary/macro_crate_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ extern crate syntax_pos;

use syntax::ast::{self, Item, MetaItem, ItemKind};
use syntax::codemap::DUMMY_SP;
use syntax::attr::{AttrMetaMethods, AttrNestedMetaItemMethods};
use syntax::ext::base::*;
use syntax::ext::quote::rt::ToTokens;
use syntax::parse::{self, token};
Expand Down

0 comments on commit 469753f

Please sign in to comment.