aboutsummaryrefslogtreecommitdiff
path: root/test/protected_mode/display.rs
diff options
context:
space:
mode:
authoriximeow <me@iximeow.net>2022-04-24 17:39:21 -0700
committeriximeow <me@iximeow.net>2022-04-24 19:22:52 -0700
commit2097524c851b15e89091fd3775817a06f0eeae4f (patch)
treee3c175856fcde170db91474ec580b549f97f8ad7 /test/protected_mode/display.rs
parente80b5622ec956a92f24ce6487fb0d76e9c541515 (diff)
fix a few issues preventing no-std builds from ... building
this includes a `Makefile` that exercises the various crate configs. most annoyingly, several doc comments needed to grow `#[cfg(feature="fmt")]` blocks so docs continue to build with that feature enabled or disabled. carved out a way to run exhaustive tests; they should be written as `#[ignore]`, and then the makefile will run even ignored tests on the expectation that this will run the exhaustive (but slower) suite. exhaustive tests are not yet written. they'll probably involve spanning 4 byte sequences from 0 to 2^32-1.
Diffstat (limited to 'test/protected_mode/display.rs')
-rw-r--r--test/protected_mode/display.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/protected_mode/display.rs b/test/protected_mode/display.rs
index 5f0c68d..f9e0d6a 100644
--- a/test/protected_mode/display.rs
+++ b/test/protected_mode/display.rs
@@ -41,9 +41,13 @@ fn test_display_under(decoder: &InstDecoder, style: DisplayStyle, data: &[u8], e
// decided i do not like at&t syntax much at all. not going to write a formatter for it. some test
// cases will live on in case someone else feels like adding one, or i get mad enough to do it.
+#[allow(unreachable_code)]
#[ignore]
#[test]
fn test_instructions_atnt() {
+ // `ignore` is now used to avoid running (slow!) exhaustive tests in a default `cargo test`.
+ // running exhaustive tests now runs these tests, which fail. so instead, return early.
+ return;
// just modrm
test_display(&[0x33, 0x08], "xor (%eax), %ecx");
test_display(&[0x33, 0x20], "xor (%eax), %esp");