Say, I have a crate with a dependency that has an optional feature. Now this feature is mostly useful for testing, but the crate itself is a dependency for the whole code. Is it possible to instruct cargo to use the feature only for testing?
In my concrete example the optional feature depends on quickcheck, which I do not necessarily want to make a mandatory dependency for users of my crate.