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

Unified Diff: Tools/GardeningServer/ui/test/ct-party-time-tests.html

Issue 459463003: Convert moar Sheriff-o-Matic tests to Polymer. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 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: Tools/GardeningServer/ui/test/ct-party-time-tests.html
diff --git a/Tools/GardeningServer/ui/test/ct-commit-tests.html b/Tools/GardeningServer/ui/test/ct-party-time-tests.html
similarity index 29%
copy from Tools/GardeningServer/ui/test/ct-commit-tests.html
copy to Tools/GardeningServer/ui/test/ct-party-time-tests.html
index 2154f3c447ef474ed909f46da76489d25d07eb03..cb96f5bfc0d1616dca11c8dbeadfe19cfb9d88c0 100644
--- a/Tools/GardeningServer/ui/test/ct-commit-tests.html
+++ b/Tools/GardeningServer/ui/test/ct-party-time-tests.html
@@ -4,34 +4,47 @@ Use of this source code is governed by a BSD-style license that can be
found in the LICENSE file.
-->
-<link rel="import" href="../ct-commit.html">
-
-<link rel="import" href="../../model/ct-commit-mock.html">
+<link rel="import" href="../ct-party-time.html">
<script>
(function () {
var assert = chai.assert;
-describe('ct-commit', function() {
- var commit;
+describe('ct-party-time', function() {
+ var partyTime;
+ var blinkFailures;
beforeEach(function(done) {
- commit = document.createElement('ct-commit');
- commit.data = new CTCommitMock();
+ partyTime = document.createElement('ct-party-time');
+
+ partyTime.failures = { blink: blinkFailures };
+ partyTime.tree = 'blink';
setTimeout(done);
});
- describe('commit UI', function() {
- it('should show example commit', function() {
- var html = commit.shadowRoot.innerHTML;
+ describe('party time: party', function() {
+ before(function() {
+ blinkFailures = [];
+ });
- assert.include(html, 'mkwst');
- assert.include(html, 'behavior for these types');
- assert.equal(commit.shadowRoot.querySelector('a').href, commit.data.url);
+ it('should have a party', function() {
+ assert(partyTime._partytime);
});
});
+
+ describe('party time: no party', function() {
+ before(function() {
+ var resultsByBuilder = {};
+ blinkFailures = [new CTFailure("step1", "reason1", resultsByBuilder, 123, 123)];
+ });
+
+ it('should not have a party', function() {
+ assert(!partyTime._partytime);
+ });
+
+ });
});
})()

Powered by Google App Engine
This is Rietveld 408576698