services/sync/tests/tps/test_tabs.js

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

     1 /* Any copyright is dedicated to the Public Domain.
     2    http://creativecommons.org/publicdomain/zero/1.0/ */
     4 /*
     5  * The list of phases mapped to their corresponding profiles.  The object
     6  * here must be in strict JSON format, as it will get parsed by the Python
     7  * testrunner (no single quotes, extra comma's, etc).
     8  */
     9 EnableEngines(["tabs"]);
    11 var phases = { "phase1": "profile1",
    12                "phase2": "profile2",
    13                "phase3": "profile1"};
    15 /*
    16  * Tab lists.
    17  */
    19 var tabs1 = [
    20   { uri: "http://hg.mozilla.org/automation/crossweave/raw-file/2d9aca9585b6/pages/page1.html",
    21     title: "Crossweave Test Page 1",
    22     profile: "profile1"
    23   },
    24   { uri: "data:text/html,<html><head><title>Hello</title></head><body>Hello</body></html>",
    25     title: "Hello",
    26     profile: "profile1"
    27   }
    28 ];
    30 var tabs2 = [
    31   { uri: "http://hg.mozilla.org/automation/crossweave/raw-file/2d9aca9585b6/pages/page3.html",
    32     title: "Crossweave Test Page 3",
    33     profile: "profile2"
    34   },
    35   { uri: "data:text/html,<html><head><title>Bye</title></head><body>Bye</body></html>",
    36     profile: "profile2"
    37   }
    38 ];
    40 /*
    41  * Test phases
    42  */
    44 Phase('phase1', [
    45   [Tabs.add, tabs1],
    46   [Sync]
    47 ]);
    49 Phase('phase2', [
    50   [Sync],
    51   [Tabs.verify, tabs1],
    52   [Tabs.add, tabs2],
    53   [Sync]
    54 ]);
    56 Phase('phase3', [
    57   [Sync],
    58   [Tabs.verify, tabs2]
    59 ]);

mercurial