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

Unified Diff: tracing/tracing/metrics/metric_map_function_test.html

Issue 3005313002: Reland Plumb trace canonicalUrl through TelemetryInfo. (Closed)
Patch Set: Created 3 years, 3 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
« no previous file with comments | « tracing/tracing/metrics/metric_map_function.html ('k') | tracing/tracing/metrics/metric_runner.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/metrics/metric_map_function_test.html
diff --git a/tracing/tracing/metrics/metric_map_function_test.html b/tracing/tracing/metrics/metric_map_function_test.html
index e449f4a0c83c179a7262b765ec4a8eaea678e928..2e74dbf9d7bbde3970903263f2debf36045392f0 100644
--- a/tracing/tracing/metrics/metric_map_function_test.html
+++ b/tracing/tracing/metrics/metric_map_function_test.html
@@ -80,5 +80,22 @@ tr.b.unittest.testSuite(function() {
}, Error, 'Illegal diagnostic name ' +
`"${tr.v.d.RESERVED_NAMES.GROUPING_PATH}" on Histogram "a"`);
});
+
+ test('validateCanonicalUrl', function() {
+ const result = new tr.mre.MreResult();
+ const m = TestUtils.newModel(model => {
+ model.canonicalUrl = 'canonical url';
+ model.metadata = [{
+ value: {
+ telemetry: {
+ traceUrls: ['trace url'],
+ },
+ },
+ }];
+ });
+ assert.throw(function() {
+ tr.metrics.metricMapFunction(result, m, {metrics: ['sampleMetric']});
+ }, Error, 'canonicalUrl "canonical url" != traceUrl "trace url"');
+ });
});
</script>
« no previous file with comments | « tracing/tracing/metrics/metric_map_function.html ('k') | tracing/tracing/metrics/metric_runner.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698