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

Unified Diff: trunk/src/chrome/test/data/pdf/basic_plugin_test.js

Issue 346693002: Revert 278043 "Re-enable PDFExtensionTest.BasicPlugin" (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 6 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 | « trunk/src/chrome/chrome_tests.gypi ('k') | trunk/src/chrome/test/data/pdf/pdf_extension_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/chrome/test/data/pdf/basic_plugin_test.js
===================================================================
--- trunk/src/chrome/test/data/pdf/basic_plugin_test.js (revision 278190)
+++ trunk/src/chrome/test/data/pdf/basic_plugin_test.js (working copy)
@@ -10,10 +10,9 @@
* Test that the page is sized to the size of the document.
*/
function testPageSize() {
- // Verify that the initial zoom is less than or equal to 100%.
- chrome.test.assertTrue(viewer.viewport.zoom <= 1);
+ // Verify that the initial zoom is 100%.
+ chrome.test.assertEq(1, viewer.viewport.zoom);
- viewer.viewport.zoom = 1;
var sizer = document.getElementById('sizer');
chrome.test.assertEq(826, sizer.offsetWidth);
chrome.test.assertEq(1066, sizer.offsetHeight);
@@ -24,10 +23,8 @@
var client = new PDFScriptingAPI(window, window.location.origin);
client.setDestinationWindow(window);
client.getAccessibilityJSON(chrome.test.callbackPass(function(json) {
- var dict = JSON.parse(json);
- chrome.test.assertEq(true, dict.copyable);
- chrome.test.assertEq(true, dict.loaded);
- chrome.test.assertEq(1, dict.numberOfPages);
+ chrome.test.assertEq('{"copyable":true,"loaded":true,"numberOfPages":1}',
+ json);
}));
},
@@ -50,10 +47,6 @@
}
];
-if (viewer.loaded) {
+window.addEventListener('pdfload', function() {
chrome.test.runTests(tests);
-} else {
- window.addEventListener('pdfload', function() {
- chrome.test.runTests(tests);
- });
-}
+});
« no previous file with comments | « trunk/src/chrome/chrome_tests.gypi ('k') | trunk/src/chrome/test/data/pdf/pdf_extension_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698