Index: LayoutTests/fast/encoding/api/replacement-encoding.html |
diff --git a/LayoutTests/fast/encoding/api/replacement-encoding.html b/LayoutTests/fast/encoding/api/replacement-encoding.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..cd7808de87b19b342242d7c6a936eb9d1ae8fb75 |
--- /dev/null |
+++ b/LayoutTests/fast/encoding/api/replacement-encoding.html |
@@ -0,0 +1,28 @@ |
+<!DOCTYPE html> |
+<script src="../../../resources/js-test.js"></script> |
+<script src="resources/shared.js"></script> |
+<script> |
+ |
+description("Verify replacement encoding behavior"); |
+ |
+shouldThrow("new TextEncoder('replacement')"); |
+shouldThrow("new TextDecoder('replacement')"); |
+ |
+encodings_table.forEach(function(section) { |
+ section.encodings.forEach(function(encoding) { |
+ if (encoding.name !== "replacement") |
+ return; |
+ |
+ encoding.labels.forEach(function(label) { |
+ |
+ debug(""); |
+ debug("label: " + label); |
+ debug(""); |
+ |
+ shouldThrow("new TextEncoder('" + label + "')"); |
+ shouldThrow("new TextDecoder('" + label + "')"); |
+ }); |
+ }); |
+}); |
+ |
+</script> |