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

Side by Side Diff: polymer_1.0.4/bower_components/iron-a11y-announcer/test/iron-a11y-announcer.html

Issue 1205703007: Add polymer 1.0 to npm_modules (Closed) Base URL: https://chromium.googlesource.com/infra/third_party/npm_modules.git@master
Patch Set: Renamed folder to 1.0.4 Created 5 years, 5 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) 2015 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 <title>iron-a11y-announcer</title>
15
16 <script src="../../webcomponentsjs/webcomponents-lite.js"></script>
17 <script src="../../web-component-tester/browser.js"></script>
18 <script src="../../test-fixture/test-fixture-mocha.js"></script>
19
20 <link rel="import" href="../../polymer/polymer.html">
21 <link rel="import" href="../../test-fixture/test-fixture.html">
22 <link rel="import" href="../iron-a11y-announcer.html">
23 </head>
24 <body>
25
26 <test-fixture id="Announcer">
27 <template>
28 <iron-a11y-announcer></iron-a11y-announcer>
29 </template>
30 </test-fixture>
31
32 <script>
33 suite('<iron-a11y-announcer>', function() {
34 var announcer;
35
36 setup(function() {
37 announcer = fixture('Announcer');
38 });
39
40 test('announces when there is an iron-announce event', function() {
41 var event = new CustomEvent('iron-announce', {
42 bubbles: true,
43 detail: {
44 text: 'foo'
45 }
46 });
47
48 sinon.spy(announcer, 'announce');
49
50 document.body.dispatchEvent(event);
51
52 expect(announcer.announce.callCount).to.be.equal(1);
53 });
54 });
55 </script>
56
57 </body>
58 </html>
59
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698