Make sure we can actually test prod code

This commit is contained in:
Christopher J. McClellan
2018-12-30 19:55:24 -05:00
parent c142db6e23
commit 0e2aadf8f2

View File

@@ -32,6 +32,10 @@ fn main() -> ! {
} }
} }
fn add(a: i32, b: i32) -> i32 {
a + b
}
#[cfg(test)] #[cfg(test)]
mod test { mod test {
use super::*; use super::*;
@@ -39,6 +43,6 @@ mod test {
#[test] #[test]
fn foo() { fn foo() {
println!("tests work!"); println!("tests work!");
assert!(1 == 1); assert!(2 == add(1,1));
} }
} }