Provide better error message when running example without features
Even better would be if "cargo run --example server" would automatically enable those features, but Cargo can't do that right now.
This commit is contained in:
parent
032b03add3
commit
95b4124f6b
2 changed files with 5 additions and 1 deletions
|
@ -15,6 +15,10 @@ name = "bench"
|
||||||
harness = false
|
harness = false
|
||||||
path = "benches/bench.rs"
|
path = "benches/bench.rs"
|
||||||
|
|
||||||
|
[[example]]
|
||||||
|
name = "server"
|
||||||
|
required-features = ["iron-handlers", "expose-test-schema"]
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
default = ["rustc-serialize"]
|
default = ["rustc-serialize"]
|
||||||
nightly = []
|
nightly = []
|
||||||
|
|
|
@ -2,7 +2,7 @@ extern crate iron;
|
||||||
extern crate mount;
|
extern crate mount;
|
||||||
extern crate logger;
|
extern crate logger;
|
||||||
extern crate rustc_serialize;
|
extern crate rustc_serialize;
|
||||||
#[macro_use] extern crate juniper;
|
extern crate juniper;
|
||||||
|
|
||||||
use std::env;
|
use std::env;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue