OLD | NEW |
(Empty) | |
| 1 <!-- |
| 2 @license |
| 3 Copyright (c) 2015 The Polymer Project Authors. All rights reserved. |
| 4 This code may only be used under the BSD style license found at http://polymer.g
ithub.io/LICENSE.txt |
| 5 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt |
| 6 The complete set of contributors may be found at http://polymer.github.io/CONTRI
BUTORS.txt |
| 7 Code distributed by Google as part of the polymer project is also |
| 8 subject to an additional IP rights grant found at http://polymer.github.io/PATEN
TS.txt |
| 9 --> |
| 10 <!doctype html> |
| 11 <html> |
| 12 <head> |
| 13 |
| 14 <title>paper-item tests</title> |
| 15 |
| 16 <meta charset="utf-8"> |
| 17 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> |
| 18 <meta name="viewport" content="width=device-width, minimum-scale=1.0, initia
l-scale=1, user-scalable=yes"> |
| 19 |
| 20 <script src="../../webcomponentsjs/webcomponents-lite.js"></script> |
| 21 |
| 22 <script src="../../web-component-tester/browser.js"></script> |
| 23 <script src="../../test-fixture/test-fixture-mocha.js"></script> |
| 24 |
| 25 <link rel="import" href="../../test-fixture/test-fixture.html"> |
| 26 <link rel="import" href="../paper-item.html"> |
| 27 <link rel="import" href="../paper-icon-item.html"> |
| 28 |
| 29 </head> |
| 30 <body> |
| 31 |
| 32 <test-fixture id="item"> |
| 33 <template> |
| 34 <paper-item>item</paper-item> |
| 35 </template> |
| 36 </test-fixture> |
| 37 |
| 38 <test-fixture id="iconItem"> |
| 39 <template> |
| 40 <paper-icon-item>item</paper-icon-item> |
| 41 </template> |
| 42 </test-fixture> |
| 43 |
| 44 <script> |
| 45 |
| 46 suite('item a11y tests', function() { |
| 47 var item, iconItem; |
| 48 |
| 49 setup(function() { |
| 50 item = fixture('item'); |
| 51 iconItem = fixture('iconItem'); |
| 52 }); |
| 53 |
| 54 test('item has role="listitem"', function() { |
| 55 assert.equal(item.getAttribute('role'), 'listitem', 'has role="item"')
; |
| 56 }); |
| 57 |
| 58 test('icon item has role="listitem"', function() { |
| 59 assert.equal(iconItem.getAttribute('role'), 'listitem', 'has role="ite
m"'); |
| 60 }); |
| 61 }); |
| 62 |
| 63 </script> |
| 64 |
| 65 </body> |
| 66 </html> |
OLD | NEW |