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

Side by Side Diff: tracing/tracing/base/assert_utils.html

Issue 2771723003: [tracing] Move math utilities from base into their own subdirectory (attempt 2) (Closed)
Patch Set: rebase Created 3 years, 9 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
« no previous file with comments | « tracing/trace_viewer.gypi ('k') | tracing/tracing/base/bbox2.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <!-- 2 <!--
3 Copyright 2016 The Chromium Authors. All rights reserved. 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 4 Use of this source code is governed by a BSD-style license that can be
5 found in the LICENSE file. 5 found in the LICENSE file.
6 --> 6 -->
7 7
8 <script> 8 <script>
9 'use strict'; 9 'use strict';
10 10
11 // TODO(charliea): Investigate whether we could make this a Chai plugin. 11 // TODO(charliea): Investigate whether we could make this a Chai plugin.
12 /** 12 /**
13 * @fileoverview Provides assert functions that are not available on the Chai 13 * @fileoverview Provides assert functions that are not available on the Chai
14 * assert module. 14 * assert module.
15 */ 15 */
16 tr.exportTo('tr.b', function() { 16 tr.exportTo('tr.b', function() {
17 /** 17 /**
18 * Throws if the range |actual| is not equal to the range |expected| (using 18 * Throws if the range |actual| is not equal to the range |expected| (using
19 * tr.b.Range.equals). 19 * tr.b.math.Range.equals).
20 */ 20 */
21 function assertRangeEquals(actual, expected) { 21 function assertRangeEquals(actual, expected) {
22 assert(actual.equals(expected), 22 assert(actual.equals(expected),
23 'Expected Range(' + actual.min + ', ' + actual.max + ') to be ' + 23 'Expected Range(' + actual.min + ', ' + actual.max + ') to be ' +
24 'Range(' + expected.min + ', ' + expected.max + ')'); 24 'Range(' + expected.min + ', ' + expected.max + ')');
25 } 25 }
26 26
27 return { 27 return {
28 assertRangeEquals, 28 assertRangeEquals,
29 }; 29 };
30 }); 30 });
31 </script> 31 </script>
OLDNEW
« no previous file with comments | « tracing/trace_viewer.gypi ('k') | tracing/tracing/base/bbox2.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698