Changeset 168048 in webkit


Ignore:
Timestamp:
Apr 30, 2014 3:03:57 PM (10 years ago)
Author:
roger_fong@apple.com
Message:

Enable snapshot tests on mac wk2.
https://bugs.webkit.org/show_bug.cgi?id=131871.
Reviewed by Darin Adler.

  • platform/mac-wk2/TestExpectations:
  • platform/mac-wk2/plugins/snapshotting/autoplay-dominant-expected.txt:
  • platform/mac-wk2/plugins/snapshotting/autoplay-plugin-blocked-by-image-expected.txt:
  • platform/mac-wk2/plugins/snapshotting/autoplay-plugin-blocked-by-image-expected.txt:
  • platform/mac-wk2/plugins/snapshotting/autoplay-similar-to-dominant-after-delay-expected.txt:
  • platform/mac-wk2/plugins/snapshotting/autoplay-similar-to-dominant-expected.txt:
  • platform/mac-wk2/plugins/snapshotting/quicktime-plugin-snapshotted-expected.txt:
  • platform/mac-wk2/plugins/snapshotting/restart-expected.txt:
  • platform/mac-wk2/plugins/snapshotting/set-plugin-size-to-tiny-expected.txt:
  • platform/mac-wk2/plugins/snapshotting/simple-expected.txt:
  • platform/mac-wk2/plugins/snapshotting/snapshot-plugin-not-quite-blocked-by-image-expected.txt:
  • plugins/snapshotting/autoplay-dominant.html:
  • plugins/snapshotting/autoplay-plugin-blocked-by-image.html:
  • plugins/snapshotting/autoplay-plugin-mostly-blocked-by-image.html:
  • plugins/snapshotting/autoplay-similar-to-dominant-after-delay.html:
  • plugins/snapshotting/autoplay-similar-to-dominant.html:
  • plugins/snapshotting/quicktime-plugin-snapshotted.html:
  • plugins/snapshotting/restart.html:
  • plugins/snapshotting/set-plugin-size-to-tiny.html:
  • plugins/snapshotting/simple.html:
  • plugins/snapshotting/snapshot-plugin-not-quite-blocked-by-image.html:
Location:
trunk/LayoutTests
Files:
22 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r168046 r168048  
     12014-04-30  Roger Fong  <roger_fong@apple.com>
     2
     3        Enable snapshot tests on mac wk2.
     4        https://bugs.webkit.org/show_bug.cgi?id=131871.
     5
     6        Reviewed by Darin Adler.
     7
     8        * platform/mac-wk2/TestExpectations:
     9        * platform/mac-wk2/plugins/snapshotting/autoplay-dominant-expected.txt:
     10        * platform/mac-wk2/plugins/snapshotting/autoplay-plugin-blocked-by-image-expected.txt:
     11        * platform/mac-wk2/plugins/snapshotting/autoplay-plugin-blocked-by-image-expected.txt:
     12        * platform/mac-wk2/plugins/snapshotting/autoplay-similar-to-dominant-after-delay-expected.txt:
     13        * platform/mac-wk2/plugins/snapshotting/autoplay-similar-to-dominant-expected.txt:
     14        * platform/mac-wk2/plugins/snapshotting/quicktime-plugin-snapshotted-expected.txt:
     15        * platform/mac-wk2/plugins/snapshotting/restart-expected.txt:
     16        * platform/mac-wk2/plugins/snapshotting/set-plugin-size-to-tiny-expected.txt:
     17        * platform/mac-wk2/plugins/snapshotting/simple-expected.txt:
     18        * platform/mac-wk2/plugins/snapshotting/snapshot-plugin-not-quite-blocked-by-image-expected.txt:
     19        * plugins/snapshotting/autoplay-dominant.html:
     20        * plugins/snapshotting/autoplay-plugin-blocked-by-image.html:
     21        * plugins/snapshotting/autoplay-plugin-mostly-blocked-by-image.html:
     22        * plugins/snapshotting/autoplay-similar-to-dominant-after-delay.html:
     23        * plugins/snapshotting/autoplay-similar-to-dominant.html:
     24        * plugins/snapshotting/quicktime-plugin-snapshotted.html:
     25        * plugins/snapshotting/restart.html:
     26        * plugins/snapshotting/set-plugin-size-to-tiny.html:
     27        * plugins/snapshotting/simple.html:
     28        * plugins/snapshotting/snapshot-plugin-not-quite-blocked-by-image.html:
     29
    1302014-04-30  David Hyatt  <hyatt@apple.com>
    231
  • trunk/LayoutTests/platform/mac-wk2/TestExpectations

    r167771 r168048  
    419419webkit.org/b/128315 editing/caret/caret-color.html [ Pass Failure ]
    420420
    421 # Temporarily disabled while working out compositing failures
    422 plugins/snapshotting [ Skip ]
    423 
    424421webkit.org/b/129468 [ MountainLion Debug ] css3/compositing/isolation-isolate-blended-child.html [ ImageOnlyFailure ]
    425422
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/autoplay-dominant-expected.txt

    r146685 r168048  
    1 layer at (0,0) size 785x650
    2   RenderView at (0,0) size 785x600
    3 layer at (0,0) size 785x650
    4   RenderBlock {HTML} at (0,0) size 785x650
    5     RenderBody {BODY} at (8,8) size 769x634
    6       RenderBlock {P} at (0,0) size 769x18
    7         RenderText {#text} at (0,0) size 334x18
    8           text run at (0,0) width 334: "This test's dominant plugin should play automatically"
    9       RenderBlock (anonymous) at (0,34) size 769x600
    10         RenderText {#text} at (0,0) size 0x0
    11 layer at (8,42) size 600x600
    12   RenderEmbeddedObject {EMBED} at (0,0) size 600x600
     1This test's dominant plugin should play automatically
     2
     3PASS
     4
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/autoplay-plugin-blocked-by-image-expected.txt

    r167960 r168048  
    1 layer at (0,0) size 785x1254
    2   RenderView at (0,0) size 785x600
    3 layer at (0,0) size 785x1254
    4   RenderBlock {HTML} at (0,0) size 785x1254
    5     RenderBody {BODY} at (8,8) size 769x1238
    6       RenderBlock {P} at (0,0) size 769x18
    7         RenderText {#text} at (0,0) size 623x18
    8           text run at (0,0) width 623: "This tests that a dominant plugin should play automatically even if an image is on top of the plugin."
    9       RenderBlock (anonymous) at (0,34) size 769x1204
    10         RenderText {#text} at (600,586) size 4x18
    11           text run at (600,586) width 4: " "
    12         RenderText {#text} at (0,0) size 0x0
    13 layer at (8,42) size 600x600
    14   RenderEmbeddedObject {EMBED} at (0,0) size 600x600
    15 layer at (8,46) size 600x600
    16   RenderImage {IMG} at (0,604) size 600x600
     1This tests that a dominant plugin should play automatically even if an image is on top of the plugin.
     2
     3PASS
     4 
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/autoplay-plugin-mostly-blocked-by-image-expected.txt

    r167960 r168048  
    1 layer at (0,0) size 785x650
    2   RenderView at (0,0) size 785x600
    3 layer at (0,0) size 785x650
    4   RenderBlock {HTML} at (0,0) size 785x650
    5     RenderBody {BODY} at (8,8) size 769x634
    6       RenderBlock {P} at (0,0) size 769x18
    7         RenderText {#text} at (0,0) size 635x18
    8           text run at (0,0) width 635: "This tests that a dominant plugin should play automatically if an image is mostly on top of the plugin."
    9       RenderBlock (anonymous) at (0,34) size 769x600
    10         RenderText {#text} at (0,0) size 0x0
    11 layer at (8,42) size 600x600
    12   RenderEmbeddedObject {EMBED} at (0,0) size 600x600
    13 layer at (0,20) size 600x600
    14   RenderImage {IMG} at (0,20) size 600x600
     1This tests that a dominant plugin should play automatically if an image is mostly on top of the plugin.
     2
     3PASS
     4 
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/autoplay-similar-to-dominant-after-delay-expected.txt

    r146946 r168048  
    1 layer at (0,0) size 785x850
    2   RenderView at (0,0) size 785x600
    3 layer at (0,0) size 785x850
    4   RenderBlock {HTML} at (0,0) size 785x850
    5     RenderBody {BODY} at (8,8) size 769x834
    6       RenderBlock {P} at (0,0) size 769x18
    7         RenderText {#text} at (0,0) size 696x18
    8           text run at (0,0) width 696: "The dominant plugin should play automatically, and then so should the identical plugin that is added a bit later."
    9       RenderBlock {DIV} at (0,34) size 769x600
    10         RenderText {#text} at (0,0) size 0x0
    11       RenderBlock {DIV} at (0,634) size 769x200
    12 layer at (8,42) size 600x600
    13   RenderEmbeddedObject {EMBED} at (0,0) size 600x600
    14 layer at (8,642) size 200x200
    15   RenderEmbeddedObject {EMBED} at (0,0) size 200x200
     1The dominant plugin should play automatically, and then so should the identical plugin that is added a bit later.
     2
     3PASS
     4
     5
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/autoplay-similar-to-dominant-expected.txt

    r146946 r168048  
    1 layer at (0,0) size 785x1056
    2   RenderView at (0,0) size 785x600
    3 layer at (0,0) size 785x1056
    4   RenderBlock {HTML} at (0,0) size 785x1056
    5     RenderBody {BODY} at (8,8) size 769x1032
    6       RenderBlock {P} at (0,0) size 769x18
    7         RenderText {#text} at (0,0) size 750x18
    8           text run at (0,0) width 750: "The dominant plugin should play automatically, and trigger all the others to play as well, since they are the same origin."
    9       RenderBlock {P} at (0,34) size 769x600
    10         RenderText {#text} at (0,0) size 0x0
    11       RenderBlock {P} at (0,650) size 769x200
    12         RenderText {#text} at (0,0) size 0x0
    13       RenderBlock {P} at (0,866) size 769x100
    14         RenderText {#text} at (0,0) size 0x0
    15       RenderBlock {P} at (0,982) size 769x50
    16         RenderText {#text} at (0,0) size 0x0
    17 layer at (8,42) size 600x600
    18   RenderEmbeddedObject {EMBED} at (0,0) size 600x600
    19 layer at (8,658) size 200x200
    20   RenderEmbeddedObject {EMBED} at (0,0) size 200x200
    21 layer at (8,874) size 100x100
    22   RenderEmbeddedObject {EMBED} at (0,0) size 100x100
    23 layer at (8,990) size 50x50
    24   RenderEmbeddedObject {EMBED} at (0,0) size 50x50
     1The dominant plugin should play automatically, and trigger all the others to play as well, since they are the same origin.
     2
     3PASS
     4
     5
     6
     7
     8
     9
     10
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/quicktime-plugin-snapshotted-expected.txt

    r152580 r168048  
    1 layer at (0,0) size 800x600
    2   RenderView at (0,0) size 800x600
    3 layer at (0,0) size 800x600
    4   RenderBlock {HTML} at (0,0) size 800x600
    5     RenderBody {BODY} at (8,8) size 784x584
    6       RenderBlock {P} at (0,0) size 784x36
    7         RenderText {#text} at (0,0) size 784x36
    8           text run at (0,0) width 407: "This test ensures that quicktime plugins can also be snapshotted. "
    9           text run at (407,0) width 377: "We make the plugin here to small to be primary plugin, thus"
    10           text run at (0,18) width 159: "it should get snapshotted."
    11       RenderBlock (anonymous) at (0,52) size 784x300
    12         RenderText {#text} at (0,0) size 0x0
    13 layer at (8,60) size 300x300
    14   RenderEmbeddedObject {EMBED} at (0,0) size 300x300
     1This test ensures that quicktime plugins can also be snapshotted. We make the plugin here too small to be the primary plugin, thus it should get snapshotted.
     2
     3PASS
     4
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/restart-expected.txt

    r146250 r168048  
    1 layer at (0,0) size 800x600
    2   RenderView at (0,0) size 800x600
    3 layer at (0,0) size 800x600
    4   RenderBlock {HTML} at (0,0) size 800x600
    5     RenderBody {BODY} at (8,8) size 784x584
    6       RenderBlock {P} at (0,0) size 784x18
    7         RenderText {#text} at (0,0) size 445x18
    8           text run at (0,0) width 445: "This test forces a plugin to snapshot immediately, then tries to restart it."
    9       RenderBlock (anonymous) at (0,34) size 784x150
    10         RenderText {#text} at (0,0) size 0x0
    11 layer at (8,42) size 300x150
    12   RenderEmbeddedObject {EMBED} at (0,0) size 300x150
     1This test forces a plugin to snapshot immediately, then tries to restart it.
     2
     3PASS
     4
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/set-plugin-size-to-tiny-expected.txt

    r167339 r168048  
    1 layer at (0,0) size 800x600
    2   RenderView at (0,0) size 800x600
    3 layer at (0,0) size 800x600
    4   RenderBlock {HTML} at (0,0) size 800x600
    5     RenderBody {BODY} at (8,8) size 784x584
    6       RenderBlock {P} at (0,0) size 784x18
    7         RenderText {#text} at (0,0) size 642x18
    8           text run at (0,0) width 642: "This test ensures that if we have set a plugin to be too small after the initial load that it still gets played."
    9       RenderBlock {P} at (0,34) size 784x18
    10         RenderText {#text} at (0,0) size 701x18
    11           text run at (0,0) width 701: "Also ensure that the plugin remains snapshotted if the size was initially specified but made too small afterwards."
    12       RenderBlock (anonymous) at (0,68) size 784x44
    13         RenderText {#text} at (40,26) size 4x18
    14           text run at (40,26) width 4: " "
    15         RenderSnapshottedPlugIn {EMBED} at (44,0) size 40x40
    16         RenderText {#text} at (0,0) size 0x0
    17 layer at (8,76) size 40x40
    18   RenderEmbeddedObject {EMBED} at (0,0) size 40x40
    19 layer at (52,76) size 40x40
    20   RenderBlock (relative positioned) {DIV} at (0,0) size 40x40
    21 layer at (57,81) size 30x30
    22   RenderFlexibleBox {DIV} at (5,5) size 30x30 [bgcolor=#FFFFFFBF]
    23     RenderBlock {DIV} at (0,-3) size 30x36
    24 layer at (57,78) size 30x18 scrollWidth 139
    25   RenderBlock {DIV} at (0,0) size 30x18
    26     RenderText {#text} at (0,0) size 139x18
    27       text run at (0,0) width 139: "Snapshotted Plug-In"
    28 layer at (57,96) size 30x18 scrollWidth 94
    29   RenderBlock {DIV} at (0,18) size 30x18 [color=#444444]
    30     RenderText {#text} at (0,0) size 94x18
    31       text run at (0,0) width 94: "Click to restart"
     1This test ensures that if we have set a plugin to be too small after the initial load that it still gets played.
     2
     3Also ensure that the plugin remains snapshotted if the size was initially specified but made too small afterwards.
     4
     5PASS
     6 
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/simple-expected.txt

    r167401 r168048  
    11This test forces a plugin to snapshot immediately
    22
    3 FAIL
     3PASS
    44
    5 
  • trunk/LayoutTests/platform/mac-wk2/plugins/snapshotting/snapshot-plugin-not-quite-blocked-by-image-expected.txt

    r167960 r168048  
    1 layer at (0,0) size 785x2214
    2   RenderView at (0,0) size 785x600
    3 layer at (0,0) size 785x2214
    4   RenderBlock {HTML} at (0,0) size 785x2214
    5     RenderBody {BODY} at (8,8) size 769x2198
    6       RenderBlock {P} at (0,0) size 769x36
    7         RenderText {#text} at (0,0) size 719x36
    8           text run at (0,0) width 719: "This tests that a plugin should be snapshotted if it is partially covered by an image but not enough to be considered"
    9           text run at (0,18) width 59: "blocking."
    10       RenderBlock {P} at (0,52) size 769x18
    11         RenderText {#text} at (0,0) size 353x18
    12           text run at (0,0) width 353: "It additionally tests that we take transforms into account."
    13       RenderBlock (anonymous) at (0,86) size 769x2112
    14         RenderSnapshottedPlugIn {EMBED} at (0,0) size 600x600
    15         RenderText {#text} at (600,586) size 4x18
    16           text run at (600,586) width 4: " "
    17         RenderText {#text} at (600,1190) size 4x18
    18           text run at (600,1190) width 4: " "
    19         RenderSnapshottedPlugIn {EMBED} at (0,1208) size 600x600
    20         RenderText {#text} at (600,1794) size 4x18
    21           text run at (600,1794) width 4: " "
    22         RenderText {#text} at (0,0) size 0x0
    23 layer at (8,94) size 600x600
    24   RenderBlock (relative positioned) {DIV} at (0,0) size 600x600
    25 layer at (13,99) size 590x590
    26   RenderFlexibleBox {DIV} at (5,5) size 590x590 [bgcolor=#FFFFFFBF]
    27     RenderBlock {DIV} at (225,277) size 140x36
    28 layer at (239,376) size 139x18
    29   RenderBlock {DIV} at (0,0) size 139x18
    30     RenderText {#text} at (0,0) size 139x18
    31       text run at (0,0) width 139: "Snapshotted Plug-In"
    32 layer at (239,394) size 139x18
    33   RenderBlock {DIV} at (0,18) size 139x18 [color=#444444]
    34     RenderText {#text} at (0,0) size 94x18
    35       text run at (0,0) width 94: "Click to restart"
    36 layer at (8,173) size 600x600
    37   RenderImage {IMG} at (0,604) size 600x600
    38 layer at (8,1302) size 600x600
    39   RenderBlock (relative positioned) {DIV} at (0,0) size 600x600
    40 layer at (13,1307) size 590x590
    41   RenderFlexibleBox {DIV} at (5,5) size 590x590 [bgcolor=#FFFFFFBF]
    42     RenderBlock {DIV} at (225,277) size 140x36
    43 layer at (239,1584) size 139x18
    44   RenderBlock {DIV} at (0,0) size 139x18
    45     RenderText {#text} at (0,0) size 139x18
    46       text run at (0,0) width 139: "Snapshotted Plug-In"
    47 layer at (239,1602) size 139x18
    48   RenderBlock {DIV} at (0,18) size 139x18 [color=#444444]
    49     RenderText {#text} at (0,0) size 94x18
    50       text run at (0,0) width 94: "Click to restart"
    51 layer at (8,1906) size 300x300
    52   RenderImage {IMG} at (0,1812) size 300x300
     1This tests that a plugin should be snapshotted if it is partially covered by an image but not enough to be considered blocking.
     2
     3It additionally tests that we take transforms into account.
     4
     5PASS
     6   
  • trunk/LayoutTests/plugins/snapshotting/autoplay-dominant.html

    r152582 r168048  
    11<p>This test's dominant plugin should play automatically</p>
     2<div id="result">FAIL</div>
    23<script>
    34if (window.testRunner) {
    4     window.internals.settings.setPlugInSnapshottingEnabled(true);
    5     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     5    internals.settings.setPlugInSnapshottingEnabled(true);
     6    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    67    testRunner.waitUntilDone();
     8    //testRunner.dumpAsText();
    79    setTimeout(function () {
     10        var result = document.getElementById("result");
     11        var embed = document.getElementById("plugin");
     12        if (!internals.isPluginSnapshotted(embed))
     13            result.innerHTML = "PASS";
    814        testRunner.notifyDone();
    9     }, 500);
     15    }, 1000);
    1016}
    1117</script>
    12 <embed src="../resources/lines.swf" width="600" height="600"></embed>
     18<embed id="plugin" src="../resources/lines.swf" width="600" height="600"></embed>
  • trunk/LayoutTests/plugins/snapshotting/autoplay-plugin-blocked-by-image.html

    r167960 r168048  
    11<p>This tests that a dominant plugin should play automatically even if an image is on top of the plugin.</p>
     2<div id="result">FAIL</div>
    23<script>
    34if (window.testRunner) {
    4     window.internals.settings.setPlugInSnapshottingEnabled(true);
    5     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     5    internals.settings.setPlugInSnapshottingEnabled(true);
     6    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    67    testRunner.waitUntilDone();
     8    testRunner.dumpAsText();
    79    setTimeout(function () {
     10        var result = document.getElementById("result");
     11        var embed = document.getElementById("plugin");
     12        if (!internals.isPluginSnapshotted(embed))
     13            result.innerHTML = "PASS";
    814        testRunner.notifyDone();
    915    }, 1000);
    1016}
    1117</script>
    12 <embed src="../resources/lines.swf" width="600" height="600"></embed>
     18<embed id="plugin" src="../resources/lines.swf" width="600" height="600"></embed>
    1319<img src="../resources/apple.gif" width="600" height="600" style="position:relative; top:-600px;">
  • trunk/LayoutTests/plugins/snapshotting/autoplay-plugin-mostly-blocked-by-image.html

    r167960 r168048  
    11<p>This tests that a dominant plugin should play automatically if an image is mostly on top of the plugin.</p>
     2<div id="result">FAIL</div>
    23<script>
    34if (window.testRunner) {
    4     window.internals.settings.setPlugInSnapshottingEnabled(true);
    5     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     5    internals.settings.setPlugInSnapshottingEnabled(true);
     6    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    67    testRunner.waitUntilDone();
     8    testRunner.dumpAsText();
    79    setTimeout(function () {
     10        var result = document.getElementById("result");
     11        var embed = document.getElementById("plugin");
     12        if (!internals.isPluginSnapshotted(embed))
     13            result.innerHTML = "PASS";
    814        testRunner.notifyDone();
    915    }, 1000);
    1016}
    1117</script>
    12 <embed src="../resources/lines.swf" width="600" height="600"></embed>
    13 <img src="../resources/apple.gif" width="600" height="600" style="position:absolute; top:20px; left:0px">
     18<embed id="plugin" src="../resources/lines.swf" width="600" height="600"></embed>
     19<img src="../resources/apple.gif" width="600" height="600" style="position:absolute; top:45px; left:0px">
  • trunk/LayoutTests/plugins/snapshotting/autoplay-similar-to-dominant-after-delay.html

    r152582 r168048  
    11<p>The dominant plugin should play automatically, and then so should the identical plugin that is added a bit later.</p>
     2<div id="result">FAIL</div>
    23<script>
    34if (window.testRunner) {
    4     window.internals.settings.setPlugInSnapshottingEnabled(true);
    5     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     5    internals.settings.setPlugInSnapshottingEnabled(true);
     6    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    67    testRunner.waitUntilDone();
     8    testRunner.dumpAsText();
    79    setTimeout(function () {
    810        var div = document.createElement("div");
    9         div.innerHTML = '<embed src="../resources/lines.swf" width="200" height="200"></embed>';
     11        div.innerHTML = '<embed id="plugin2" src="../resources/lines.swf" width="200" height="200"></embed>';
    1012        document.body.appendChild(div);
    1113        setTimeout(function () {
     14            var result = document.getElementById("result");
     15            var embed1 = document.getElementById("plugin1");
     16                        var embed2 = document.getElementById("plugin2");
     17            if (!(internals.isPluginSnapshotted(embed1)
     18                || internals.isPluginSnapshotted(embed2)))
     19                result.innerHTML = "PASS";
    1220            testRunner.notifyDone();
    13         }, 500);
     21        }, 1000);
    1422    }, 500);
    1523}
    1624</script>
    1725<div>
    18 <embed src="../resources/lines.swf" width="600" height="600"></embed>
     26<embed id="plugin1" src="../resources/lines.swf" width="600" height="600"></embed>
    1927</div>
  • trunk/LayoutTests/plugins/snapshotting/autoplay-similar-to-dominant.html

    r152582 r168048  
    11<p>The dominant plugin should play automatically, and trigger all the others to play as well, since they are the same origin.</p>
     2<div id="result">FAIL</div>
    23<script>
    34if (window.testRunner) {
    4     window.internals.settings.setPlugInSnapshottingEnabled(true);
    5     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     5    internals.settings.setPlugInSnapshottingEnabled(true);
     6    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    67    testRunner.waitUntilDone();
     8    testRunner.dumpAsText();
    79    setTimeout(function () {
     10        var result = document.getElementById("result");
     11        var embed1 = document.getElementById("plugin1");
     12        var embed2 = document.getElementById("plugin2");
     13        var embed3 = document.getElementById("plugin3");
     14        var embed4 = document.getElementById("plugin4");
     15        if (!(internals.isPluginSnapshotted(embed1)
     16            || internals.isPluginSnapshotted(embed2)
     17            || internals.isPluginSnapshotted(embed3)
     18            || internals.isPluginSnapshotted(embed4)))
     19            result.innerHTML = "PASS";
    820        testRunner.notifyDone();
    9     }, 500);
     21    }, 2000);
    1022}
    1123</script>
    1224<p>
    13 <embed src="../resources/lines.swf" width="600" height="600"></embed>
     25<embed id="plugin1" src="../resources/lines.swf" width="600" height="600"></embed>
    1426</p>
    1527<p>
    16 <embed src="../resources/lines.swf" width="200" height="200"></embed>
     28<embed id="plugin2" src="../resources/lines.swf" width="200" height="200"></embed>
    1729</p>
    1830<p>
    19 <embed src="../resources/lines.swf" width="100" height="100"></embed>
     31<embed id="plugin3" src="../resources/lines.swf" width="100" height="100"></embed>
    2032</p>
    2133<p>
    22 <embed src="../resources/lines.swf" width="50" height="50"></embed>
     34<embed id="plugin4" src="../resources/lines.swf" width="50" height="50"></embed>
    2335</p>
  • trunk/LayoutTests/plugins/snapshotting/quicktime-plugin-snapshotted.html

    r152580 r168048  
    11<p>This test ensures that quicktime plugins can also be snapshotted.
    22We make the plugin here too small to be the primary plugin, thus it should get snapshotted.</p>
     3<div id="result">FAIL</div>
    34<script>
    45if (window.testRunner) {
    5     window.internals.settings.setPlugInSnapshottingEnabled(true);
    6     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     6    internals.settings.setPlugInSnapshottingEnabled(true);
     7    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    78    testRunner.waitUntilDone();
     9    testRunner.dumpAsText();
    810    setTimeout(function () {
     11        var result = document.getElementById("result");
     12        var embed = document.getElementById("plugin");
     13        if (internals.isPluginSnapshotted(embed))
     14            result.innerHTML = "PASS";
    915        testRunner.notifyDone();
    1016    }, 500);
    1117}
    1218</script>
    13 <embed src="../resources/orange.mov" width="300" height="300"></embed>
     19<embed id="plugin" src="../resources/orange.mov" width="300" height="300"></embed>
  • trunk/LayoutTests/plugins/snapshotting/restart.html

    r152582 r168048  
    11<p>This test forces a plugin to snapshot immediately, then tries to restart it.</p>
     2<div id="result">FAIL</div>
    23<script>
    34if (window.testRunner) {
    4     window.internals.settings.setPlugInSnapshottingEnabled(true);
    5     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     5    internals.settings.setPlugInSnapshottingEnabled(true);
     6    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    67    testRunner.waitUntilDone();
     8    testRunner.dumpAsText();
    79    setTimeout(function () {
    8         var embed = document.querySelector("embed");
     10        var embed = document.getElementById("plugin");
    911        var rect = embed.getBoundingClientRect();
    1012        eventSender.mouseMoveTo(rect.left + 10, rect.top + 10);
     
    1214        eventSender.mouseUp();
    1315        setTimeout(function () {
     16            var result = document.getElementById("result");
     17            var embed = document.getElementById("plugin");
     18            if (!internals.isPluginSnapshotted(embed))
     19                result.innerHTML = "PASS";
    1420            testRunner.notifyDone();
    15         }, 500);
    16     }, 500);
     21        }, 1000);
     22    }, 1000);
    1723}
    1824</script>
    19 <embed src="../resources/lines.swf"></embed>
     25<embed id="plugin" src="../resources/lines.swf"></embed>
  • trunk/LayoutTests/plugins/snapshotting/set-plugin-size-to-tiny.html

    r167339 r168048  
    11<p>This test ensures that if we have set a plugin to be too small after the initial load that it still gets played.</p>
    22<p>Also ensure that the plugin remains snapshotted if the size was initially specified but made too small afterwards.</p>
     3<div id="result">FAIL</div>
    34<script>
    45if (window.testRunner) {
    5     window.internals.settings.setPlugInSnapshottingEnabled(true);
    6     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     6    internals.settings.setPlugInSnapshottingEnabled(true);
     7    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    78    testRunner.waitUntilDone();
     9    testRunner.dumpAsText();
    810    setTimeout(function () {
    9         var embedElement = document.getElementById("embed");
    10         embedElement.style.width = 40;
    11         embedElement.style.height = 40;
    12         var embedElement2 = document.getElementById("embed2");
    13         embedElement2.style.width = 40;
    14         embedElement2.style.height = 40;
     11        var result = document.getElementById("result");
     12        var embed1 = document.getElementById("plugin1");
     13        embed1.style.width = 40;
     14        embed1.style.height = 40;
     15        var embed2 = document.getElementById("plugin2");
     16        embed2.style.width = 40;
     17        embed2.style.height = 40;
     18        if (!internals.isPluginSnapshotted(embed1) && internals.isPluginSnapshotted(embed2))
     19            result.innerHTML = "PASS";
    1520        testRunner.notifyDone();
    1621    }, 2000);
    1722}
    1823</script>
    19 <embed id="embed" src="../resources/lines.swf"></embed>
    20 <embed id="embed2" src="../resources/lines.swf" style="width:300px; height:300px"></embed>
     24<embed id="plugin1" src="../resources/lines.swf"></embed>
     25<embed id="plugin2" src="../resources/lines.swf" style="width:300px; height:300px"></embed>
  • trunk/LayoutTests/plugins/snapshotting/simple.html

    r167401 r168048  
    11<p>This test forces a plugin to snapshot immediately</p>
    2 <p id="passStatus">PASS</p>
     2<div id="result">FAIL</div>
    33<script>
    44if (window.testRunner) {
    5     window.internals.settings.setPlugInSnapshottingEnabled(true);
    6     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     5    internals.settings.setPlugInSnapshottingEnabled(true);
     6    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    77    testRunner.waitUntilDone();
    88    testRunner.dumpAsText();
    99    setTimeout(function () {
    10         var plugin = document.getElementById("plugin");
    11         var passStatus = document.getElementById("passStatus");
    12         if (!window.internals.isPluginSnapshotted(plugin))
    13             passStatus.innerHTML = "FAIL";
     10        var result = document.getElementById("result");
     11        var embed = document.getElementById("plugin");
     12        if (internals.isPluginSnapshotted(embed))
     13            result.innerHTML = "PASS";
    1414        testRunner.notifyDone();
    15     }, 500);
     15    }, 1000);
    1616}
    1717</script>
  • trunk/LayoutTests/plugins/snapshotting/snapshot-plugin-not-quite-blocked-by-image.html

    r167960 r168048  
    11<p>This tests that a plugin should be snapshotted if it is partially covered by an image but not enough to be considered blocking.</p>
    22<p> It additionally tests that we take transforms into account. </p>
     3<div id="result">FAIL</div>
    34<script>
    45if (window.testRunner) {
    5     window.internals.settings.setPlugInSnapshottingEnabled(true);
    6     window.internals.settings.setMaximumPlugInSnapshotAttempts(0);
     6    internals.settings.setPlugInSnapshottingEnabled(true);
     7    internals.settings.setMaximumPlugInSnapshotAttempts(0);
    78    testRunner.waitUntilDone();
     9    testRunner.dumpAsText();
    810    setTimeout(function () {
     11        var result = document.getElementById("result");
     12        var embed1 = document.getElementById("plugin1");
     13        var embed2 = document.getElementById("plugin2");
     14        if (internals.isPluginSnapshotted(embed1) && internals.isPluginSnapshotted(embed2))
     15            result.innerHTML = "PASS";
    916        testRunner.notifyDone();
    1017    }, 1000);
    1118}
    1219</script>
    13 <embed src="../resources/lines.swf" width="600" height="600"></embed>
     20<embed id="plugin1" src="../resources/lines.swf" width="600" height="600"></embed>
    1421<img src="../resources/apple.gif" width="600" height="600" style="position:relative; top:-525px; left:0px">
    15 <embed src="../resources/lines.swf" width="600" height="600"></embed>
     22<embed id="plugin2" src="../resources/lines.swf" width="600" height="600"></embed>
    1623<img src="../resources/apple.gif" width="300" height="300" style="-webkit-transform:translate(-500px,-200px)">
Note: See TracChangeset for help on using the changeset viewer.