maud/maud_macros/tests/warnings.rs
Isaac van Bakel f1f67e5aac Added compile tests to check keyword warning
compiletest_rs is now used to check that elements which have keyword
names are now warned against in a UI test.
compiletest_rs has been added as a build dependency.
2018-10-19 22:39:11 +01:00

15 lines
471 B
Rust

extern crate compiletest_rs;
use std::path::PathBuf;
#[test]
fn run_warnings() {
let mut config = compiletest_rs::Config::default();
config.mode = compiletest_rs::common::Mode::Ui;
config.src_base = PathBuf::from("tests/warnings");
config.link_deps(); // Populate config.target_rustcflags with dependencies on the path
config.clean_rmeta(); // If your tests import the parent crate, this helps with E0464
compiletest_rs::run_tests(&config);
}