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

Unified Diff: bower_components/polymer-collapse/test/html/polymer-collapse.html

Issue 786953007: npm_modules: Fork bower_components into Polymer 0.4.0 and 0.5.0 versions (Closed) Base URL: https://chromium.googlesource.com/infra/third_party/npm_modules.git@master
Patch Set: Created 5 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: bower_components/polymer-collapse/test/html/polymer-collapse.html
diff --git a/bower_components/polymer-collapse/test/html/polymer-collapse.html b/bower_components/polymer-collapse/test/html/polymer-collapse.html
deleted file mode 100644
index c34c3803788452bccc615ca4b53739bd1b5dd01c..0000000000000000000000000000000000000000
--- a/bower_components/polymer-collapse/test/html/polymer-collapse.html
+++ /dev/null
@@ -1,57 +0,0 @@
-<!doctype html>
-<html>
-<head>
- <title>polymer-collapse</title>
- <script src="../../../platform/platform.js"></script>
- <script src="../../../tools/test/htmltest.js"></script>
- <script src="../../../tools/test/chai/chai.js"></script>
- <link rel="import" href="../../polymer-collapse.html">
-</head>
-<body>
- <button onclick="document.querySelector('#collapse').toggle()">toggle collapse</button>
- <div id="box">
- Forma temperiemque cornua sidera dissociata cornua recessit innabilis ligavit: solidumque coeptis nullus caelum sponte phoebe di regat mentisque tanta austro capacius amphitrite sui quin postquam semina fossae liquidum umor galeae coeptis caligine liberioris quin liquidum matutinis invasit posset: flexi glomeravit radiis certis invasit oppida postquam onerosior inclusum dominari opifex terris pace finxit quam aquae nunc sine altae auroram quam habentem homo totidemque scythiam in pondus ensis tegit caecoque poena lapidosos humanas coeperunt poena aetas totidem nec natura aethera locavit caelumque distinxit animalibus phoebe cingebant moderantum porrexerat terrae possedit sua sole diu summaque obliquis melioris orbem
- </div>
- <polymer-collapse id="collapse" targetId="box" duration="0.1"></polymer-collapse>
-
- <script>
- var assert = chai.assert;
- var delay = 200;
- document.addEventListener('polymer-ready', function() {
- var c = document.querySelector('#collapse');
- assert.equal(c.closed, false);
- Platform.flush();
- setTimeout(function() {
- var origH = getBoxComputedHeight();
- assert.notEqual(origH, 0);
- c.closed = true;
- Platform.flush();
- setTimeout(function() {
- // after closed, height is 0
- assert.equal(getBoxComputedHeight(), 0);
- // should be set to display: none
- assert.equal(getBoxComputedStyle().display, 'none');
- c.closed = false;
- Platform.flush();
- setTimeout(function() {
- // verify computed height
- assert.equal(getBoxComputedHeight(), origH);
- // after opened, height is set to 'auto'
- assert.equal(document.querySelector('#box').style.height, 'auto');
- done();
- }, delay);
- }, delay);
- }, delay);
- });
-
- function getBoxComputedStyle() {
- var b = document.querySelector('#box');
- return getComputedStyle(b);
- }
-
- function getBoxComputedHeight() {
- return parseInt(getBoxComputedStyle().height);
- }
- </script>
-</body>
-</html>
« no previous file with comments | « bower_components/polymer-collapse/polymer-collapse.html ('k') | bower_components/polymer-collapse/test/js/polymer-collapse.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698