| <script src="../../resources/js-test-pre.js"></script> |
| <div id="editor" contenteditable>hello<img src="../resources/abe.png"></div> |
| description('This tests makes sure that pasting content while images are disabled does not enable deferred loading.') |
| testFailed('This test requires internals.settings'); |
| document.execCommand("selectAll"); |
| evalAndLog('internals.settings.setImagesEnabled(false)'); |
| evalAndLog('document.execCommand("copy")'); |
| shouldBe('editor.querySelector("img").width', '76'); |
| evalAndLog('setTimeout(waitForImagesToBeDisabled, 0)'); |
| function waitForImagesToBeDisabled() |
| shouldBeFalse('internals.pageDefersLoading()'); |
| evalAndLog('document.execCommand("paste")'); |
| shouldBeFalse('internals.pageDefersLoading()'); |
| <script src="../../resources/js-test-post.js"></script> |