diff options
author | Sascha Grunert <mail@saschagrunert.de> | 2017-02-22 15:15:08 +0100 |
---|---|---|
committer | Sascha Grunert <mail@saschagrunert.de> | 2017-02-22 15:15:08 +0100 |
commit | 8abc917d29a078555759508702d77b4d5f5a6b23 (patch) | |
tree | 2f4e3d58be1618a3653a6c74ddfac53635ac59c6 /src | |
parent | Improved API and unit test (diff) | |
download | wireguard-rs-8abc917d29a078555759508702d77b4d5f5a6b23.tar.xz wireguard-rs-8abc917d29a078555759508702d77b4d5f5a6b23.zip |
Improved unit testing
Diffstat (limited to 'src')
-rw-r--r-- | src/error.rs | 5 | ||||
-rw-r--r-- | src/lib.rs | 4 |
2 files changed, 5 insertions, 4 deletions
diff --git a/src/error.rs b/src/error.rs index 0314dfb..220ed27 100644 --- a/src/error.rs +++ b/src/error.rs @@ -10,10 +10,11 @@ pub type WgResult<T> = Result<T, WgError>; /// The global Error type for wiki pub struct WgError { /// A further description for the error - pub description: String, + description: String, + #[allow(dead_code)] /// The cause for this error - pub cause: Option<Box<Error>>, + cause: Option<Box<Error>>, } /// Representation of an error case @@ -13,12 +13,12 @@ extern crate futures; extern crate mowl; #[macro_use] -pub mod error; +mod error; mod device; mod bindgen; pub use device::Device; -use error::WgResult; +pub use error::{WgResult, WgError}; use std::io; use std::net::SocketAddr; |