aboutsummaryrefslogtreecommitdiff
path: root/tests/test_spans.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_spans.rs')
-rw-r--r--tests/test_spans.rs19
1 files changed, 2 insertions, 17 deletions
diff --git a/tests/test_spans.rs b/tests/test_spans.rs
index cb3ee18..74724a5 100644
--- a/tests/test_spans.rs
+++ b/tests/test_spans.rs
@@ -326,8 +326,6 @@ fn annotate_errors(html: &'static str) -> String {
}
}
- let doesnt_support_utf16 = std::sync::Mutex::new(false);
-
let labeler = |tokens| {
let mut labels = Vec::new();
for token in tokens {
@@ -336,25 +334,12 @@ fn annotate_errors(html: &'static str) -> String {
};
labels.push((span, error.code()));
-
- use html5tokenizer::Error;
-
- *doesnt_support_utf16.lock().unwrap() = matches!(
- error,
- | Error::EndTagWithTrailingSolidus // FIXME
- );
}
labels
};
- // This will be removed once all tested errors support UTF-16.
- let _ = labeler(Box::new(tokenizer(html)) as TokenIter);
- if *doesnt_support_utf16.lock().unwrap() {
- assert_panics_but_should_not(|| assert_char_encoding_independence(html, labeler));
- } else {
- // TODO: Move this assertion into test_and_annotate once all tests support it.
- assert_char_encoding_independence(html, labeler);
- }
+ // TODO: Move this assertion into test_and_annotate once all tests support it.
+ assert_char_encoding_independence(html, labeler);
test_and_annotate(html, labeler)
}