Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(97)

Unified Diff: LayoutTests/fast/encoding/api/encoding-labels.html

Issue 240283013: Convert Encoding API tests to W3C testharness.js (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/fast/encoding/api/encoding-labels.html
diff --git a/LayoutTests/fast/encoding/api/encoding-labels.html b/LayoutTests/fast/encoding/api/encoding-labels.html
index 1958e97902927bb90c2abecd1e44817a05b974ad..a809ff3fb73647d68c6663f0975739848f1f6d5e 100644
--- a/LayoutTests/fast/encoding/api/encoding-labels.html
+++ b/LayoutTests/fast/encoding/api/encoding-labels.html
@@ -1,18 +1,18 @@
<!DOCTYPE html>
-<script src="../../../resources/js-test.js"></script>
+<title>Encoding API: Encoding labels</title>
+<script src="../../../resources/testharness.js"></script>
+<script src="../../../resources/testharnessreport.js"></script>
<script src="resources/shared.js"></script>
<script>
-description("Test the Encoding API's use of encoding names");
-
encodings_table.forEach(function(section) {
- var list = section.encodings;
- list.forEach(function(encoding) {
- debug("");
- evalAndLog("name = " + JSON.stringify(encoding.name));
- encoding.labels.forEach(function(label) {
- shouldBeEqualToString("new TextDecoder(" + JSON.stringify(label) + ").encoding", encoding.name);
- });
+ section.encodings.forEach(function(encoding) {
+ var name = encoding.name;
+ test(function(){
+ encoding.labels.forEach(function(label) {
+ assert_equals(new TextDecoder(label).encoding, encoding.name);
+ });
+ }, 'Labels for: ' + name);
});
});

Powered by Google App Engine
This is Rietveld 408576698