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

Side by Side Diff: tracing/tracing/value/ui/related_histogram_set_span_test.html

Issue 2998043002: Remove RelatedHistogramSet. (Closed)
Patch Set: Created 3 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 unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <!--
3 Copyright 2016 The Chromium Authors. All rights reserved.
4 Use of this source code is governed by a BSD-style license that can be
5 found in the LICENSE file.
6 -->
7
8 <link rel="import" href="/tracing/value/diagnostics/related_histogram_set.html">
9 <link rel="import" href="/tracing/value/histogram.html">
10 <link rel="import" href="/tracing/value/ui/diagnostic_span.html">
11
12 <script>
13 'use strict';
14
15 tr.b.unittest.testSuite(function() {
16 test('instantiate_RelatedHistogramSet', function() {
17 const aValue = new tr.v.Histogram('foo', tr.b.Unit.byName.unitlessNumber);
18 const bValue = new tr.v.Histogram('bar', tr.b.Unit.byName.unitlessNumber);
19 const diagnostic = new tr.v.d.RelatedHistogramSet([aValue, bValue]);
20 const span = tr.v.ui.createDiagnosticSpan(diagnostic);
21 assert.strictEqual('TR-V-UI-RELATED-HISTOGRAM-SET-SPAN', span.tagName);
22 this.addHTMLOutput(span);
23 assert.isDefined(tr.ui.b.findDeepElementMatchingPredicate(
24 span, function(element) {
25 return element.textContent === 'Select All';
26 }));
27 assert.isDefined(tr.ui.b.findDeepElementMatchingPredicate(
28 span, function(element) {
29 return element.textContent === 'foo';
30 }));
31 assert.isDefined(tr.ui.b.findDeepElementMatchingPredicate(
32 span, function(element) {
33 return element.textContent === 'bar';
34 }));
35 });
36 });
37 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698