提交 07cc7d99 编写于 作者: J Johannes Oertel

Change name of unit test sub-module to "tests".

Changes the style guidelines regarding unit tests to recommend using a
sub-module named "tests" instead of "test" for unit tests as "test"
might clash with imports of libtest.
上级 2214860d
% Unit testing % Unit testing
Unit tests should live in a `test` submodule at the bottom of the module they Unit tests should live in a `tests` submodule at the bottom of the module they
test. Mark the `test` submodule with `#[cfg(test)]` so it is only compiled when test. Mark the `tests` submodule with `#[cfg(test)]` so it is only compiled when
testing. testing.
The `test` module should contain: The `tests` module should contain:
* Imports needed only for testing. * Imports needed only for testing.
* Functions marked with `#[test]` striving for full coverage of the parent module's * Functions marked with `#[test]` striving for full coverage of the parent module's
...@@ -17,7 +17,7 @@ For example: ...@@ -17,7 +17,7 @@ For example:
// Excerpt from std::str // Excerpt from std::str
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
#[test] #[test]
fn test_eq() { fn test_eq() {
assert!((eq(&"".to_owned(), &"".to_owned()))); assert!((eq(&"".to_owned(), &"".to_owned())));
......
...@@ -219,10 +219,10 @@ fn it_works() { ...@@ -219,10 +219,10 @@ fn it_works() {
This is a very common use of `assert_eq!`: call some function with This is a very common use of `assert_eq!`: call some function with
some known arguments and compare it to the expected output. some known arguments and compare it to the expected output.
# The `test` module # The `tests` module
There is one way in which our existing example is not idiomatic: it's There is one way in which our existing example is not idiomatic: it's
missing the test module. The idiomatic way of writing our example missing the `tests` module. The idiomatic way of writing our example
looks like this: looks like this:
```{rust,ignore} ```{rust,ignore}
...@@ -231,7 +231,7 @@ pub fn add_two(a: i32) -> i32 { ...@@ -231,7 +231,7 @@ pub fn add_two(a: i32) -> i32 {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::add_two; use super::add_two;
#[test] #[test]
...@@ -241,7 +241,7 @@ mod test { ...@@ -241,7 +241,7 @@ mod test {
} }
``` ```
There's a few changes here. The first is the introduction of a `mod test` with There's a few changes here. The first is the introduction of a `mod tests` with
a `cfg` attribute. The module allows us to group all of our tests together, and a `cfg` attribute. The module allows us to group all of our tests together, and
to also define helper functions if needed, that don't become a part of the rest to also define helper functions if needed, that don't become a part of the rest
of our crate. The `cfg` attribute only compiles our test code if we're of our crate. The `cfg` attribute only compiles our test code if we're
...@@ -260,7 +260,7 @@ pub fn add_two(a: i32) -> i32 { ...@@ -260,7 +260,7 @@ pub fn add_two(a: i32) -> i32 {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
#[test] #[test]
...@@ -279,7 +279,7 @@ $ cargo test ...@@ -279,7 +279,7 @@ $ cargo test
Running target/adder-91b3e234d4ed382a Running target/adder-91b3e234d4ed382a
running 1 test running 1 test
test test::it_works ... ok test tests::it_works ... ok
test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured
...@@ -292,7 +292,7 @@ test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured ...@@ -292,7 +292,7 @@ test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured
It works! It works!
The current convention is to use the `test` module to hold your "unit-style" The current convention is to use the `tests` module to hold your "unit-style"
tests. Anything that just tests one small bit of functionality makes sense to tests. Anything that just tests one small bit of functionality makes sense to
go here. But what about "integration-style" tests instead? For that, we have go here. But what about "integration-style" tests instead? For that, we have
the `tests` directory the `tests` directory
...@@ -325,7 +325,7 @@ $ cargo test ...@@ -325,7 +325,7 @@ $ cargo test
Running target/adder-91b3e234d4ed382a Running target/adder-91b3e234d4ed382a
running 1 test running 1 test
test test::it_works ... ok test tests::it_works ... ok
test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured
...@@ -346,7 +346,7 @@ test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured ...@@ -346,7 +346,7 @@ test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured
Now we have three sections: our previous test is also run, as well as our new Now we have three sections: our previous test is also run, as well as our new
one. one.
That's all there is to the `tests` directory. The `test` module isn't needed That's all there is to the `tests` directory. The `tests` module isn't needed
here, since the whole thing is focused on tests. here, since the whole thing is focused on tests.
Let's finally check out that third section: documentation tests. Let's finally check out that third section: documentation tests.
...@@ -382,7 +382,7 @@ pub fn add_two(a: i32) -> i32 { ...@@ -382,7 +382,7 @@ pub fn add_two(a: i32) -> i32 {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
#[test] #[test]
...@@ -405,7 +405,7 @@ $ cargo test ...@@ -405,7 +405,7 @@ $ cargo test
Running target/adder-91b3e234d4ed382a Running target/adder-91b3e234d4ed382a
running 1 test running 1 test
test test::it_works ... ok test tests::it_works ... ok
test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured
......
...@@ -384,7 +384,7 @@ pub fn stats_print() {} ...@@ -384,7 +384,7 @@ pub fn stats_print() {}
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
extern crate test; extern crate test;
use self::test::Bencher; use self::test::Bencher;
use boxed::Box; use boxed::Box;
......
...@@ -933,7 +933,7 @@ fn hash<H: Hasher>(&self, state: &mut H) { ...@@ -933,7 +933,7 @@ fn hash<H: Hasher>(&self, state: &mut H) {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use std::clone::Clone; use std::clone::Clone;
use std::iter::{Iterator, IntoIterator}; use std::iter::{Iterator, IntoIterator};
use std::option::Option::{Some, None, self}; use std::option::Option::{Some, None, self};
......
...@@ -1772,7 +1772,7 @@ fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { ...@@ -1772,7 +1772,7 @@ fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use core::iter::{Iterator, self}; use core::iter::{Iterator, self};
use core::option::Option::Some; use core::option::Option::Some;
......
...@@ -45,7 +45,7 @@ pub fn test_num<T>(ten: T, two: T) where ...@@ -45,7 +45,7 @@ pub fn test_num<T>(ten: T, two: T) where
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use core::option::Option; use core::option::Option;
use core::option::Option::{Some, None}; use core::option::Option::{Some, None};
use core::num::Float; use core::num::Float;
......
...@@ -202,7 +202,7 @@ fn rand<R: Rng>(other: &mut R) -> ChaChaRng { ...@@ -202,7 +202,7 @@ fn rand<R: Rng>(other: &mut R) -> ChaChaRng {
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use std::prelude::v1::*; use std::prelude::v1::*;
use core::iter::order; use core::iter::order;
......
...@@ -82,7 +82,7 @@ fn ind_sample<R: Rng>(&self, rng: &mut R) -> f64 { ...@@ -82,7 +82,7 @@ fn ind_sample<R: Rng>(&self, rng: &mut R) -> f64 {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use std::prelude::v1::*; use std::prelude::v1::*;
use distributions::{Sample, IndependentSample}; use distributions::{Sample, IndependentSample};
......
...@@ -276,7 +276,7 @@ fn ind_sample<R: Rng>(&self, rng: &mut R) -> f64 { ...@@ -276,7 +276,7 @@ fn ind_sample<R: Rng>(&self, rng: &mut R) -> f64 {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use std::prelude::v1::*; use std::prelude::v1::*;
use distributions::{Sample, IndependentSample}; use distributions::{Sample, IndependentSample};
......
...@@ -510,7 +510,7 @@ fn rand<R: Rng>(other: &mut R) -> Isaac64Rng { ...@@ -510,7 +510,7 @@ fn rand<R: Rng>(other: &mut R) -> Isaac64Rng {
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use std::prelude::v1::*; use std::prelude::v1::*;
use core::iter::order; use core::iter::order;
......
...@@ -120,7 +120,7 @@ fn default() -> ReseedWithDefault { ReseedWithDefault } ...@@ -120,7 +120,7 @@ fn default() -> ReseedWithDefault { ReseedWithDefault }
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use std::prelude::v1::*; use std::prelude::v1::*;
use core::iter::{order, repeat}; use core::iter::{order, repeat};
......
...@@ -1111,7 +1111,7 @@ fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { ...@@ -1111,7 +1111,7 @@ fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use session::config::{build_configuration, optgroups, build_session_options}; use session::config::{build_configuration, optgroups, build_session_options};
use session::build_session; use session::build_session;
......
...@@ -41,7 +41,7 @@ fn realpath(pathname: *const libc::c_char, resolved: *mut libc::c_char) ...@@ -41,7 +41,7 @@ fn realpath(pathname: *const libc::c_char, resolved: *mut libc::c_char)
} }
#[cfg(all(not(windows), test))] #[cfg(all(not(windows), test))]
mod test { mod tests {
use tempdir::TempDir; use tempdir::TempDir;
use std::fs::{self, File}; use std::fs::{self, File};
use super::realpath; use super::realpath;
......
...@@ -171,7 +171,7 @@ fn minimize_rpaths(rpaths: &[String]) -> Vec<String> { ...@@ -171,7 +171,7 @@ fn minimize_rpaths(rpaths: &[String]) -> Vec<String> {
} }
#[cfg(all(unix, test))] #[cfg(all(unix, test))]
mod test { mod tests {
use super::{RPathConfig}; use super::{RPathConfig};
use super::{minimize_rpaths, rpaths_to_flags, get_rpath_relative_to_output}; use super::{minimize_rpaths, rpaths_to_flags, get_rpath_relative_to_output};
use std::path::{Path, PathBuf}; use std::path::{Path, PathBuf};
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
use snapshot_vec::{SnapshotVec, SnapshotVecDelegate}; use snapshot_vec::{SnapshotVec, SnapshotVecDelegate};
#[cfg(test)] #[cfg(test)]
mod test; mod tests;
pub struct Graph<N,E> { pub struct Graph<N,E> {
nodes: SnapshotVec<Node<N>> , nodes: SnapshotVec<Node<N>> ,
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
use snapshot_vec as sv; use snapshot_vec as sv;
#[cfg(test)] #[cfg(test)]
mod test; mod tests;
/// This trait is implemented by any type that can serve as a type /// This trait is implemented by any type that can serve as a type
/// variable. We call such variables *unification keys*. For example, /// variable. We call such variables *unification keys*. For example,
......
...@@ -198,7 +198,7 @@ fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result { ...@@ -198,7 +198,7 @@ fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::{TocBuilder, Toc, TocEntry}; use super::{TocBuilder, Toc, TocEntry};
#[test] #[test]
......
...@@ -117,7 +117,7 @@ pub unsafe fn symbol<T>(&self, symbol: &str) -> Result<*mut T, String> { ...@@ -117,7 +117,7 @@ pub unsafe fn symbol<T>(&self, symbol: &str) -> Result<*mut T, String> {
} }
#[cfg(all(test, not(target_os = "ios")))] #[cfg(all(test, not(target_os = "ios")))]
mod test { mod tests {
use super::*; use super::*;
use prelude::v1::*; use prelude::v1::*;
use libc; use libc;
......
...@@ -418,7 +418,7 @@ pub fn _print(args: fmt::Arguments) { ...@@ -418,7 +418,7 @@ pub fn _print(args: fmt::Arguments) {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use thread; use thread;
use super::*; use super::*;
......
...@@ -102,7 +102,7 @@ fn flush(&mut self) -> io::Result<()> { Ok(()) } ...@@ -102,7 +102,7 @@ fn flush(&mut self) -> io::Result<()> { Ok(()) }
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use io::prelude::*; use io::prelude::*;
......
...@@ -346,7 +346,7 @@ fn drop(&mut self) { ...@@ -346,7 +346,7 @@ fn drop(&mut self) {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use sync::mpsc::channel; use sync::mpsc::channel;
......
...@@ -63,7 +63,7 @@ fn fill_bytes(&mut self, mut v: &mut [u8]) { ...@@ -63,7 +63,7 @@ fn fill_bytes(&mut self, mut v: &mut [u8]) {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use super::ReaderRng; use super::ReaderRng;
......
...@@ -38,7 +38,7 @@ pub fn log_enabled() -> bool { ...@@ -38,7 +38,7 @@ pub fn log_enabled() -> bool {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use sys_common; use sys_common;
macro_rules! t { ($a:expr, $b:expr) => ({ macro_rules! t { ($a:expr, $b:expr) => ({
......
...@@ -155,7 +155,7 @@ pub fn spawn<F>(blk: F) -> Future<A> ...@@ -155,7 +155,7 @@ pub fn spawn<F>(blk: F) -> Future<A>
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use sync::mpsc::channel; use sync::mpsc::channel;
use sync::Future; use sync::Future;
......
...@@ -1065,7 +1065,7 @@ fn cause(&self) -> Option<&error::Error> { ...@@ -1065,7 +1065,7 @@ fn cause(&self) -> Option<&error::Error> {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use std::env; use std::env;
......
...@@ -346,7 +346,7 @@ fn next(&mut self) -> Option<*mut Handle<'static, ()>> { ...@@ -346,7 +346,7 @@ fn next(&mut self) -> Option<*mut Handle<'static, ()>> {
#[cfg(test)] #[cfg(test)]
#[allow(unused_imports)] #[allow(unused_imports)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use thread; use thread;
......
...@@ -241,7 +241,7 @@ fn drop(&mut self) { ...@@ -241,7 +241,7 @@ fn drop(&mut self) {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use sync::Arc; use sync::Arc;
......
...@@ -361,7 +361,7 @@ pub fn guard_poison<'a, T>(guard: &MutexGuard<'a, T>) -> &'a poison::Flag { ...@@ -361,7 +361,7 @@ pub fn guard_poison<'a, T>(guard: &MutexGuard<'a, T>) -> &'a poison::Flag {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use sync::mpsc::channel; use sync::mpsc::channel;
......
...@@ -121,7 +121,7 @@ pub fn call_once<F>(&'static self, f: F) where F: FnOnce() { ...@@ -121,7 +121,7 @@ pub fn call_once<F>(&'static self, f: F) where F: FnOnce() {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use thread; use thread;
......
...@@ -151,7 +151,7 @@ fn drop(&mut self) { ...@@ -151,7 +151,7 @@ fn drop(&mut self) {
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use sys_common::remutex::{ReentrantMutex, ReentrantMutexGuard}; use sys_common::remutex::{ReentrantMutex, ReentrantMutexGuard};
use cell::RefCell; use cell::RefCell;
......
...@@ -722,7 +722,7 @@ fn _assert_both<T: Send + Sync>() {} ...@@ -722,7 +722,7 @@ fn _assert_both<T: Send + Sync>() {}
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use prelude::v1::*; use prelude::v1::*;
use any::Any; use any::Any;
......
...@@ -1869,7 +1869,7 @@ pub struct MacroDef { ...@@ -1869,7 +1869,7 @@ pub struct MacroDef {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use serialize; use serialize;
use super::*; use super::*;
......
...@@ -632,7 +632,7 @@ pub fn lit_is_str(lit: &Lit) -> bool { ...@@ -632,7 +632,7 @@ pub fn lit_is_str(lit: &Lit) -> bool {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use ast::*; use ast::*;
use super::*; use super::*;
......
...@@ -949,7 +949,7 @@ pub struct MalformedCodemapPositions { ...@@ -949,7 +949,7 @@ pub struct MalformedCodemapPositions {
// //
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
use std::rc::Rc; use std::rc::Rc;
......
...@@ -1553,7 +1553,7 @@ fn visit_mac(&mut self, mac: &ast::Mac) { ...@@ -1553,7 +1553,7 @@ fn visit_mac(&mut self, mac: &ast::Mac) {
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::{pattern_bindings, expand_crate}; use super::{pattern_bindings, expand_crate};
use super::{PatIdentFinder, IdentRenamer, PatIdentRenamer, ExpansionConfig}; use super::{PatIdentFinder, IdentRenamer, PatIdentRenamer, ExpansionConfig};
use ast; use ast;
......
...@@ -1343,7 +1343,7 @@ pub fn noop_fold_stmt<T: Folder>(Spanned {node, span}: Stmt, folder: &mut T) ...@@ -1343,7 +1343,7 @@ pub fn noop_fold_stmt<T: Folder>(Spanned {node, span}: Stmt, folder: &mut T)
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use std::io; use std::io;
use ast; use ast;
use util::parser_testing::{string_to_crate, matches_codepattern}; use util::parser_testing::{string_to_crate, matches_codepattern};
......
...@@ -383,7 +383,7 @@ pub fn gather_comments_and_literals(span_diagnostic: &diagnostic::SpanHandler, ...@@ -383,7 +383,7 @@ pub fn gather_comments_and_literals(span_diagnostic: &diagnostic::SpanHandler,
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
#[test] fn test_block_doc_comment_1() { #[test] fn test_block_doc_comment_1() {
......
...@@ -1501,7 +1501,7 @@ fn ident_continue(c: Option<char>) -> bool { ...@@ -1501,7 +1501,7 @@ fn ident_continue(c: Option<char>) -> bool {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
use codemap::{BytePos, CodeMap, Span, NO_EXPANSION}; use codemap::{BytePos, CodeMap, Span, NO_EXPANSION};
......
...@@ -761,7 +761,7 @@ pub fn integer_lit(s: &str, suffix: Option<&str>, sd: &SpanHandler, sp: Span) -> ...@@ -761,7 +761,7 @@ pub fn integer_lit(s: &str, suffix: Option<&str>, sd: &SpanHandler, sp: Span) ->
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
use std::rc::Rc; use std::rc::Rc;
use codemap::{Span, BytePos, Pos, Spanned, NO_EXPANSION}; use codemap::{Span, BytePos, Pos, Spanned, NO_EXPANSION};
......
...@@ -746,7 +746,7 @@ pub fn fresh_mark() -> ast::Mrk { ...@@ -746,7 +746,7 @@ pub fn fresh_mark() -> ast::Mrk {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
use ast; use ast;
use ext::mtwt; use ext::mtwt;
......
...@@ -3008,7 +3008,7 @@ pub fn print_unsafety(&mut self, s: ast::Unsafety) -> io::Result<()> { ...@@ -3008,7 +3008,7 @@ pub fn print_unsafety(&mut self, s: ast::Unsafety) -> io::Result<()> {
fn repeat(s: &str, n: usize) -> String { iter::repeat(s).take(n).collect() } fn repeat(s: &str, n: usize) -> String { iter::repeat(s).take(n).collect() }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
use ast; use ast;
......
...@@ -142,7 +142,7 @@ pub fn is_whitespace(c: char) -> bool { ...@@ -142,7 +142,7 @@ pub fn is_whitespace(c: char) -> bool {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
#[test] fn eqmodws() { #[test] fn eqmodws() {
......
...@@ -204,7 +204,7 @@ fn move_map<F>(self, mut f: F) -> SmallVector<T> where F: FnMut(T) -> T { ...@@ -204,7 +204,7 @@ fn move_map<F>(self, mut f: F) -> SmallVector<T> where F: FnMut(T) -> T {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::*; use super::*;
#[test] #[test]
......
...@@ -573,7 +573,7 @@ fn format(val: Param, op: FormatOp, flags: Flags) -> Result<Vec<u8> ,String> { ...@@ -573,7 +573,7 @@ fn format(val: Param, op: FormatOp, flags: Flags) -> Result<Vec<u8> ,String> {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::{expand,Param,Words,Variables,Number}; use super::{expand,Param,Words,Variables,Number};
use std::result::Result::Ok; use std::result::Result::Ok;
......
...@@ -345,7 +345,7 @@ pub fn msys_terminfo() -> Box<TermInfo> { ...@@ -345,7 +345,7 @@ pub fn msys_terminfo() -> Box<TermInfo> {
} }
#[cfg(test)] #[cfg(test)]
mod test { mod tests {
use super::{boolnames, boolfnames, numnames, numfnames, stringnames, stringfnames}; use super::{boolnames, boolfnames, numnames, numfnames, stringnames, stringfnames};
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
// compile-flags:--test // compile-flags:--test
// ignore-pretty turns out the pretty-printer doesn't handle gensym'd things... // ignore-pretty turns out the pretty-printer doesn't handle gensym'd things...
mod test { mod tests {
use super::*; use super::*;
#[test] #[test]
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册