Changeset 246804 in webkit


Ignore:
Timestamp:
Jun 25, 2019 1:48:36 PM (5 years ago)
Author:
wilander@apple.com
Message:

Migrate LayoutTests/http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store* test cases to setEnableFeature() and jsTestIsAsync
https://bugs.webkit.org/show_bug.cgi?id=199180
<rdar://problem/52085369>

Reviewed by Brent Fulgham.

  • http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store-expected.txt:
  • http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store-one-hour-expected.txt:
  • http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store-one-hour.html:
  • http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store.html:
Location:
trunk/LayoutTests
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r246799 r246804  
     12019-06-25  John Wilander  <wilander@apple.com>
     2
     3        Migrate LayoutTests/http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store* test cases to setEnableFeature() and jsTestIsAsync
     4        https://bugs.webkit.org/show_bug.cgi?id=199180
     5        <rdar://problem/52085369>
     6
     7        Reviewed by Brent Fulgham.
     8
     9        * http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store-expected.txt:
     10        * http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store-one-hour-expected.txt:
     11        * http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store-one-hour.html:
     12        * http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store.html:
     13
    1142019-06-25  Russell Epstein  <russell_e@apple.com>
    215
  • trunk/LayoutTests/http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store-expected.txt

    r229152 r246804  
     1Tests clearing of website data store.
     2
     3On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
     4
     5
     6PASS Host classified as prevalent resource.
     7PASS Host is no longer a prevalent resource after the store was cleared.
    18PASS successfullyParsed is true
    29
    310TEST COMPLETE
    4 PASS Host classified as prevalent resource.
    5 PASS Host is no longer a prevalent resource after the store was cleared.
    611
  • trunk/LayoutTests/http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store-one-hour-expected.txt

    r229152 r246804  
     1Tests clearing of website data store (one hour).
     2
     3On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
     4
     5
     6PASS Host classified as prevalent resource.
     7PASS Host is no longer a prevalent resource after the store was cleared.
    18PASS successfullyParsed is true
    29
    310TEST COMPLETE
    4 PASS Host classified as prevalent resource.
    5 PASS Host is no longer a prevalent resource after the store was cleared.
    611
  • trunk/LayoutTests/http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store-one-hour.html

    r233888 r246804  
    33<head>
    44    <meta charset="UTF-8">
    5     <title>Test Cleared Store</title>
     5    <title></title>
    66    <script src="/js-test-resources/js-test.js"></script>
     7    <script src="resources/util.js"></script>
    78</head>
    89<body>
    910<script>
     11    description("Tests clearing of website data store (one hour).");
     12    jsTestIsAsync = true;
     13
    1014    const hostUnderTest = "127.0.0.1:8000";
    1115    const statisticsUrl = "http://" + hostUnderTest + "/temp";
     
    2024            testPassed("Host is no longer a prevalent resource after the store was cleared.");
    2125
    22         internals.setResourceLoadStatisticsEnabled(false);
    23         testRunner.statisticsResetToConsistentState(function() {
    24             testRunner.notifyDone();
    25         });
     26        setEnableFeature(false, finishJSTest);
    2627    }
    2728
     
    5657
    5758    if (document.location.host === hostUnderTest && window.testRunner && window.internals) {
    58         testRunner.waitUntilDone();
    59         internals.setResourceLoadStatisticsEnabled(true);
    60         runTestRunnerTest();
     59        setEnableFeature(true, function () {
     60            runTestRunnerTest();
     61        });
    6162    }
    6263</script>
  • trunk/LayoutTests/http/tests/resourceLoadStatistics/clear-in-memory-and-persistent-store.html

    r233888 r246804  
    55    <title>Test Cleared Store</title>
    66    <script src="/js-test-resources/js-test.js"></script>
     7    <script src="resources/util.js"></script>
    78</head>
    89<body>
    910<script>
     11    description("Tests clearing of website data store.");
     12    jsTestIsAsync = true;
     13
    1014    const hostUnderTest = "127.0.0.1:8000";
    1115    const statisticsUrl = "http://" + hostUnderTest + "/temp";
     
    2933            testPassed("Host is no longer a prevalent resource after the store was cleared.");
    3034
    31         internals.setResourceLoadStatisticsEnabled(false);
    32         testRunner.statisticsResetToConsistentState(function() {
    33             testRunner.notifyDone();
    34         });
     35        setEnableFeature(false, finishJSTest);
    3536    }
    3637
     
    5758
    5859    if (document.location.host === hostUnderTest && window.testRunner && window.internals) {
    59         testRunner.waitUntilDone();
    60         internals.setResourceLoadStatisticsEnabled(true);
    61         runTestRunnerTest();
     60        setEnableFeature(true, function () {
     61            runTestRunnerTest();
     62        });
    6263    }
    6364</script>
Note: See TracChangeset for help on using the changeset viewer.