Replace "cfg(test)" with "cfg(doctest)" for readme testing

This commit is contained in:
Guillaume Gomez 2020-05-07 12:04:22 +02:00 committed by Geoffroy Couprie
parent e766634631
commit 28fb84634d

View File

@ -407,7 +407,7 @@
#[cfg(all(not(feature = "std"), feature = "alloc"))]
#[macro_use]
extern crate alloc;
#[cfg(test)]
#[cfg(doctest)]
extern crate doc_comment;
#[cfg(feature = "lexical")]
extern crate lexical_core;
@ -417,9 +417,8 @@ pub extern crate regex;
#[cfg(nightly)]
extern crate test;
//FIXME: reactivate doctest once https://github.com/rust-lang/rust/issues/62210 is done
//#[cfg(doctest)]
//doc_comment::doctest!("../README.md");
#[cfg(doctest)]
doc_comment::doctest!("../README.md");
/// Lib module to re-export everything needed from `std` or `core`/`alloc`. This is how `serde` does
/// it, albeit there it is not public.