Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / inspector / user-metrics.html
blobdaa963c85cf7a823c2d9dd01fcd8200611476ca3
1 <html>
2 <head>
3 <script src="../http/tests/inspector/inspector-test.js"></script>
4 <script src="../http/tests/inspector/timeline-test.js"></script>
5 <script src="profiler/profiler-test.js"></script>
6 <script src="audits/audits-test.js"></script>
7 <script>
9 function test()
11 InspectorFrontendHost.recordEnumeratedHistogram = function(name, code)
13 if (name === "DevTools.ActionTaken")
14 InspectorTest.addResult("Action taken: " + nameOf(WebInspector.UserMetrics._ActionCodes, code));
15 else if (name === "DevTools.PanelShown")
16 InspectorTest.addResult("Panel shown: " + nameOf(WebInspector.UserMetrics._PanelCodes, code));
19 function nameOf(object, code)
21 for (var name in object) {
22 if (object[name] === code)
23 return name;
25 return null;
28 InspectorTest.addResult("recordActionTaken:");
29 InspectorTest.dump(WebInspector.UserMetrics._ActionCodes);
30 WebInspector.userMetrics.WindowDocked.record();
31 WebInspector.userMetrics.WindowUndocked.record();
33 InspectorTest.addResult("\nrecordPanelShown:");
34 InspectorTest.dump(WebInspector.UserMetrics._PanelCodes);
35 WebInspector.ProfilesPanel.show();
36 WebInspector.TimelinePanel.show();
37 WebInspector.AuditsPanel.show();
39 InspectorTest.completeTest();
42 </script>
43 </head>
45 <body onload="runTest()">
46 <p>Tests list of user metrics codes and invocations.</p>
48 </body>
49 </html>