From 92bbc3595c39e964160660a2de9aa76b72ce727f Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Tue, 14 Jul 2026 19:01:50 +0100 Subject: Convert Rust examples to use cargo test --- .../07-native-type-custom-config/output/rust/src/main.rs | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'examples/07-native-type-custom-config') diff --git a/examples/07-native-type-custom-config/output/rust/src/main.rs b/examples/07-native-type-custom-config/output/rust/src/main.rs index af7be7f..164fa14 100644 --- a/examples/07-native-type-custom-config/output/rust/src/main.rs +++ b/examples/07-native-type-custom-config/output/rust/src/main.rs @@ -1,9 +1,13 @@ mod point; -use point::Line; - struct Point(i32, i32); -fn main() { - let line = Line { start: Point(10, 25), end: Point(25, 10) }; +#[cfg(test)] +mod test { + use super::{Point, point::Line}; + + #[test] + fn can_use_native_types() { + let line = Line { start: Point(10, 25), end: Point(25, 10) }; + } } -- cgit v1.2.3