summaryrefslogtreecommitdiff
path: root/systest
diff options
context:
space:
mode:
authorWez Furlong <wez@wezfurlong.org>2019-07-23 16:39:28 -0700
committerWez Furlong <wez@wezfurlong.org>2019-07-29 08:55:06 -0700
commit18dc0f59e0b29c50da525dbe85d36fb5cb0ecf62 (patch)
tree5f424e77c3bc053a39aea417fea6fe75b963f1d9 /systest
parent78d2e3d9dbf1530cdf4bc152b91f0ddd7ce4895b (diff)
downloadssh2-rs-18dc0f59e0b29c50da525dbe85d36fb5cb0ecf62.zip
cargo fmt
No functional changes, just formatting
Diffstat (limited to 'systest')
-rw-r--r--systest/build.rs23
-rw-r--r--systest/src/main.rs2
2 files changed, 11 insertions, 14 deletions
diff --git a/systest/build.rs b/systest/build.rs
index 4a2d2b4..6131643 100644
--- a/systest/build.rs
+++ b/systest/build.rs
@@ -5,20 +5,17 @@ use std::env;
fn main() {
let mut cfg = ctest::TestGenerator::new();
cfg.header("libssh2.h")
- .header("libssh2_publickey.h")
- .header("libssh2_sftp.h")
- .include(env::var("DEP_SSH2_INCLUDE").unwrap())
- .type_name(|s, is_struct| {
- if (is_struct || s == "stat") && !s.starts_with("LIB") {
- format!("struct {}", s)
- } else {
- s.to_string()
- }
+ .header("libssh2_publickey.h")
+ .header("libssh2_sftp.h")
+ .include(env::var("DEP_SSH2_INCLUDE").unwrap())
+ .type_name(|s, is_struct| {
+ if (is_struct || s == "stat") && !s.starts_with("LIB") {
+ format!("struct {}", s)
+ } else {
+ s.to_string()
+ }
})
.skip_type(|t| t.ends_with("FUNC"))
- .skip_fn(|f| {
- f == "libssh2_userauth_password_ex" ||
- f == "libssh2_session_init_ex"
- });
+ .skip_fn(|f| f == "libssh2_userauth_password_ex" || f == "libssh2_session_init_ex");
cfg.generate("../libssh2-sys/lib.rs", "all.rs");
}
diff --git a/systest/src/main.rs b/systest/src/main.rs
index 7fe430a..d020e50 100644
--- a/systest/src/main.rs
+++ b/systest/src/main.rs
@@ -1,7 +1,7 @@
#![allow(bad_style, improper_ctypes)]
-extern crate libssh2_sys;
extern crate libc;
+extern crate libssh2_sys;
use libc::*;
use libssh2_sys::*;