my-greeting-basic.html 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  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.github.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/CONTRIBUTORS.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/PATENTS.txt
  10. -->
  11. <html>
  12. <head>
  13. <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1.0, user-scalable=yes">
  14. <title>my-greeting-basic</title>
  15. <script src="../bower_components/webcomponentsjs/webcomponents-lite.min.js"></script>
  16. <script src="../bower_components/web-component-tester/browser.js"></script>
  17. <!-- Import the element to test -->
  18. <link rel="import" href="../elements/my-greeting/my-greeting.html">
  19. </head>
  20. <body>
  21. <test-fixture id="basic">
  22. <template>
  23. <my-greeting></my-greeting>
  24. </template>
  25. </test-fixture>
  26. <script>
  27. suite('my-greeting tests', function() {
  28. var greeting, header;
  29. setup(function() {
  30. greeting = fixture('basic');
  31. });
  32. test('Welcome!', function() {
  33. header = greeting.querySelector('h2');
  34. assert.equal(header.textContent, 'Welcome!');
  35. });
  36. });
  37. </script>
  38. </body>
  39. </html>