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

Side by Side Diff: LayoutTests/fast/encoding/api/encoding-labels.html

Issue 269593009: Encoding API: Update tests and simplify constructors (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <title>Encoding API: Encoding labels</title> 2 <title>Encoding API: Encoding labels</title>
3 <script src="../../../resources/testharness.js"></script> 3 <script src="../../../resources/testharness.js"></script>
4 <script src="../../../resources/testharnessreport.js"></script> 4 <script src="../../../resources/testharnessreport.js"></script>
5 <script src="resources/shared.js"></script> 5 <script src="resources/shared.js"></script>
6 <script> 6 <script>
7 7
8 encodings_table.forEach(function(section) { 8 encodings_table.forEach(function(section) {
9 section.encodings.forEach(function(encoding) { 9 section.encodings.filter(function(encoding) {
10 return encoding.name !== 'replacement';
11 }).forEach(function(encoding) {
10 var name = encoding.name; 12 var name = encoding.name;
11 test(function(){ 13 test(function(){
12 encoding.labels.forEach(function(label) { 14 encoding.labels.forEach(function(label) {
13 assert_equals(new TextDecoder(label).encoding, encoding.name); 15 assert_equals(new TextDecoder(label).encoding, encoding.name);
14 }); 16 });
15 }, 'Labels for: ' + name); 17 }, 'Labels for: ' + name);
16 }); 18 });
17 }); 19 });
18 20
19 </script> 21 </script>
OLDNEW
« no previous file with comments | « LayoutTests/fast/encoding/api/ascii-supersets-expected.txt ('k') | LayoutTests/fast/encoding/api/encoding-labels-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698