I have a constants defined in a lib.rs as follows:
const GREEN: LedColor = LedColor(0, 255, 0);
In the same lib.rs file I also have tests trying to use GREEN as follows:
#[cfg(test)]
mod tests {
use {OFF, YELLOW, RED, GREEN};
#[test]
fn some_test() {//...}
But running cargo test gives an error such as:
no GREEN in path
How do I reference the constant GREEN in a test that's in the same file?