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

Side by Side Diff: third_party/polymer/components/iron-icons/test/iron-icons.html

Issue 3010683002: Update Polymer components. (Closed)
Patch Set: Rebase Created 3 years, 3 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
OLDNEW
(Empty)
1 <!doctype html>
2 <!--
3 @license
4 Copyright (c) 2016 The Polymer Project Authors. All rights reserved.
5 This code may only be used under the BSD style license found at http://polymer.g ithub.io/LICENSE.txt
6 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
7 The complete set of contributors may be found at http://polymer.github.io/CONTRI BUTORS.txt
8 Code distributed by Google as part of the polymer project is also
9 subject to an additional IP rights grant found at http://polymer.github.io/PATEN TS.txt
10 -->
11
12 <html>
13 <head>
14
15 <title>iron-icons</title>
16 <meta charset="utf-8">
17 <meta name="viewport" content="width=device-width, initial-scale=1.0">
18
19 <script src="../../webcomponentsjs/webcomponents-lite.js"></script>
20 <script src="../../web-component-tester/browser.js"></script>
21
22 <link rel="import" href="../av-icons.html">
23 <link rel="import" href="../communication-icons.html">
24 <link rel="import" href="../device-icons.html">
25 <link rel="import" href="../editor-icons.html">
26 <link rel="import" href="../hardware-icons.html">
27 <link rel="import" href="../image-icons.html">
28 <link rel="import" href="../iron-icons.html">
29 <link rel="import" href="../maps-icons.html">
30 <link rel="import" href="../notification-icons.html">
31 <link rel="import" href="../places-icons.html">
32 <link rel="import" href="../social-icons.html">
33
34 </head>
35 <body>
36
37 <script>
38
39 suite('<iron-icons>', function() {
40 suite('basic behavior', function() {
41 var meta;
42 var iconsetNames = [
43 'av', 'communication', 'device', 'editor', 'hardware', 'icons', 'image',
44 'maps', 'notification', 'places', 'social'
45 ];
46
47 setup(function() {
48 meta = Polymer.Base.create('iron-meta', {type: 'iconset'});
49 });
50
51 test('all uniquely named', function() {
52 var allIcons = {};
53 for (var i = 0; i < iconsetNames.length; i++) {
54 var iconset = meta.byKey(iconsetNames[i]);
55 expect(iconset).to.be.ok;
56
57 var iconNames = iconset.getIconNames();
58 expect(iconNames).to.not.be.empty;
59
60 for (var j = 0; j < iconNames.length; j++) {
61 var parts = iconNames[j].split(':');
62 expect(parts).to.have.length(2);
63 expect(parts[0]).to.equal(iconsetNames[i]);
64 expect(parts[1]).to.have.length.at.least(1);
65 expect(allIcons.hasOwnProperty(parts[1])).to.be.false;
66
67 allIcons[parts[1]] = true;
68 }
69 }
70
71 // Sanity check.
72 expect(Object.getOwnPropertyNames(allIcons))
73 .to.have.length.of.at.least(iconsetNames.length);
74 });
75 });
76 });
77
78 </script>
79
80 </body>
81 </html>
OLDNEW
« no previous file with comments | « third_party/polymer/components/iron-icons/test/index.html ('k') | third_party/polymer/components/iron-iconset-svg/.bower.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698