1#![allow(non_upper_case_globals)]
2#![allow(non_camel_case_types)]
3#![allow(non_snake_case)]
4
5include!(concat!(env!("OUT_DIR"), "/bindings.rs"));
6
7#[cfg(test)]
13mod tests {
14 use super::*;
15
16 #[test]
17 fn init_openthread() {
18 unsafe {
19 let instance = otInstanceInitSingle();
20 let initted = otInstanceIsInitialized(instance);
21
22 match initted {
23 r if r == (true as _) => panic!("Instance should not be initialised already"),
24 r if r == (false as _) => {},
25 r => panic!("Unknown return value = {}", r),
26 }
27 }
28 }
29}