| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <head> | 2 <head> |
| 3 <script src="../http/tests/inspector/inspector-test.js"></script> | 3 <script src="../http/tests/inspector/inspector-test.js"></script> |
| 4 <script src="./resources/blink-fs.js"></script> | 4 <script src="./resources/blink-fs.js"></script> |
| 5 <script> | 5 <script> |
| 6 function test() | 6 function test() |
| 7 { | 7 { |
| 8 const TestQueries = [ | 8 const TestQueries = [ |
| 9 ["textejs", "./Source/devtools/front_end/TextEditor.js"], | 9 ["textejs", "./Source/devtools/front_end/TextEditor.js"], |
| 10 ["defted", "./Source/devtools/front_end/DefaultTextEditor.js"], | 10 ["defted", "./Source/devtools/front_end/DefaultTextEditor.js"], |
| 11 ["CMTE", "./Source/devtools/front_end/CodeMirrorTextEditor.js"], | 11 ["CMTE", "./Source/devtools/front_end/CodeMirrorTextEditor.js"], |
| 12 ["frocmte", "./Source/devtools/front_end/CodeMirrorTextEditor.js"], | 12 ["frocmte", "./Source/devtools/front_end/CodeMirrorTextEditor.js"], |
| 13 ["cmtejs", "./Source/devtools/front_end/CodeMirrorTextEditor.js"], | 13 ["cmtejs", "./Source/devtools/front_end/CodeMirrorTextEditor.js"], |
| 14 ["setscr", "./Source/devtools/front_end/SettingsScreen.js"], | 14 ["setscr", "./Source/devtools/front_end/SettingsScreen.js"], |
| 15 ["cssnfv", "./Source/devtools/front_end/CSSNamedFlowView.js"], | 15 ["cssnfv", "./Source/devtools/front_end/CSSNamedFlowView.js"], |
| 16 ["jssf", "./Source/devtools/front_end/JavaScriptSourceFrame.js"], | 16 ["jssf", "./Source/devtools/front_end/JavaScriptSourceFrame.js"], |
| 17 ["sofrajs", "./Source/devtools/front_end/SourceFrame.js"], | 17 ["sofrajs", "./Source/devtools/front_end/SourceFrame.js"], |
| 18 ["inspeins", "./Source/core/inspector/InspectorInstrumentation.cpp"], | 18 ["inspeins", "./Source/core/inspector/InspectorInstrumentation.cpp"], |
| 19 ["froscr", "./Source/devtools/front_end/Script.js"], | 19 ["froscr", "./Source/devtools/front_end/Script.js"], |
| 20 ["adscon", "./Source/devtools/front_end/AdvancedSearchController.js"] | 20 ["adscon", "./Source/devtools/front_end/AdvancedSearchController.js"] |
| 21 ]; | 21 ]; |
| 22 | 22 |
| 23 WebInspector.showPanel("scripts"); | 23 WebInspector.showPanel("sources"); |
| 24 InspectorTest.evaluateInPage("blinkFilePaths()", step1); | 24 InspectorTest.evaluateInPage("blinkFilePaths()", step1); |
| 25 InspectorTest.addResult("Expected score must be equal to the actual score"); | 25 InspectorTest.addResult("Expected score must be equal to the actual score"); |
| 26 | 26 |
| 27 function step1(filePaths) | 27 function step1(filePaths) |
| 28 { | 28 { |
| 29 var files = filePaths.value.split(":"); | 29 var files = filePaths.value.split(":"); |
| 30 InspectorTest.addResult("Test set size: " + files.length); | 30 InspectorTest.addResult("Test set size: " + files.length); |
| 31 for(var i = 0; i < TestQueries.length; ++i) { | 31 for(var i = 0; i < TestQueries.length; ++i) { |
| 32 runQuery(files, TestQueries[i][0], TestQueries[i][1]); | 32 runQuery(files, TestQueries[i][0], TestQueries[i][1]); |
| 33 } | 33 } |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 result += "<"; | 78 result += "<"; |
| 79 return result + " (score: " + score + ")"; | 79 return result + " (score: " + score + ")"; |
| 80 } | 80 } |
| 81 }; | 81 }; |
| 82 </script> | 82 </script> |
| 83 </head> | 83 </head> |
| 84 <body onload="runTest()"> | 84 <body onload="runTest()"> |
| 85 <p>Test file path scoring function</p> | 85 <p>Test file path scoring function</p> |
| 86 </body> | 86 </body> |
| 87 </html> | 87 </html> |
| OLD | NEW |