| 1 |
--- a/Cargo.toml |
| 2 |
+++ b/Cargo.toml |
| 3 |
@@ -31,6 +31,9 @@ |
| 4 |
license = "MIT OR Apache-2.0" |
| 5 |
repository = "https://github.com/libseccomp-rs/libseccomp-rs" |
| 6 |
|
| 7 |
+[lib] |
| 8 |
+doctest = false |
| 9 |
+ |
| 10 |
[package.metadata.docs.rs] |
| 11 |
all-features = true |
| 12 |
rustc-args = [ |
| 13 |
--- a/tests/notify.rs |
| 14 |
+++ b/tests/notify.rs |
| 15 |
@@ -124,6 +124,7 @@ |
| 16 |
} |
| 17 |
|
| 18 |
#[test] |
| 19 |
+#[ignore = "known to be flaky"] |
| 20 |
fn test_error() { |
| 21 |
skip_if_not_supported!(); |
| 22 |
|
| 23 |
--- a/tests/tests.rs |
| 24 |
+++ b/tests/tests.rs |
| 25 |
@@ -21,6 +21,8 @@ |
| 26 |
} |
| 27 |
|
| 28 |
#[test] |
| 29 |
+#[ignore = "known to be flaky" |
| 30 |
+] |
| 31 |
fn test_check_api() { |
| 32 |
assert!(check_api(3, ScmpVersion::from((2, 4, 0))).unwrap()); |
| 33 |
assert!(!check_api(100, ScmpVersion::from((2, 4, 0))).unwrap()); |
| 34 |
@@ -266,6 +268,7 @@ |
| 35 |
|
| 36 |
#[test] |
| 37 |
#[cfg(feature = "const-syscall")] |
| 38 |
+#[cfg(not(target_arch = "s390x"))] |
| 39 |
fn test_syscall_new() { |
| 40 |
for name in known_syscall_names::KNOWN_SYSCALL_NAMES { |
| 41 |
if let Ok(nr) = ScmpSyscall::from_name(name) { |
| 42 |
@@ -285,6 +288,7 @@ |
| 43 |
} |
| 44 |
|
| 45 |
#[test] |
| 46 |
+#[cfg(not(any(target_arch = "s390x", target_arch = "powerpc64", target_arch = "powerpc")))] |
| 47 |
fn test_builder_pattern() -> Result<(), Box<dyn std::error::Error>> { |
| 48 |
let mut ctx = ScmpFilterContext::new(ScmpAction::Allow)?; |
| 49 |
ctx.add_arch(ScmpArch::Arm)?; |
| 50 |
@@ -330,6 +334,7 @@ |
| 51 |
} |
| 52 |
|
| 53 |
#[test] |
| 54 |
+#[cfg(not(target_endian = "big"))] |
| 55 |
fn test_arch_functions() { |
| 56 |
let mut ctx = ScmpFilterContext::new(ScmpAction::Allow).unwrap(); |
| 57 |
ctx.add_arch(ScmpArch::X86).unwrap(); |
| 58 |
@@ -342,6 +347,7 @@ |
| 59 |
} |
| 60 |
|
| 61 |
#[test] |
| 62 |
+#[cfg(not(target_endian = "big"))] |
| 63 |
fn test_merge_filters() { |
| 64 |
let mut ctx1 = ScmpFilterContext::new(ScmpAction::Allow).unwrap(); |
| 65 |
let mut ctx2 = ScmpFilterContext::new(ScmpAction::Allow).unwrap(); |
| 66 |
--- a/src/api.rs |
| 67 |
+++ b/src/api.rs |
| 68 |
@@ -129,6 +129,7 @@ |
| 69 |
use super::*; |
| 70 |
|
| 71 |
#[test] |
| 72 |
+ #[cfg(not(target_arch = "loong64"))] |
| 73 |
fn test_ensure_supported_api() { |
| 74 |
assert!(ensure_supported_api("test", 3, ScmpVersion::from((2, 4, 0))).is_ok()); |
| 75 |
assert!(ensure_supported_api("test", 100, ScmpVersion::from((2, 4, 0))).is_err()); |