|
1 /* Any copyright is dedicated to the Public Domain. |
|
2 http://creativecommons.org/publicdomain/zero/1.0/ */ |
|
3 |
|
4 // Bug 532173 - Dont sync tabs like about:* , weave firstrun etc |
|
5 |
|
6 /* |
|
7 * The list of phases mapped to their corresponding profiles. The object |
|
8 * here must be in strict JSON format, as it will get parsed by the Python |
|
9 * testrunner (no single quotes, extra comma's, etc). |
|
10 */ |
|
11 EnableEngines(["tabs"]); |
|
12 |
|
13 var phases = { "phase1": "profile1", |
|
14 "phase2": "profile2" }; |
|
15 |
|
16 var tabs1 = [ |
|
17 { uri: "data:text/html,<html><head><title>Firefox</title></head><body>Firefox</body></html>", |
|
18 title: "Firefox", |
|
19 profile: "profile1" |
|
20 }, |
|
21 { uri: "about:plugins", |
|
22 title: "About", |
|
23 profile: "profile1" |
|
24 }, |
|
25 { uri: "about:credits", |
|
26 title: "Credits", |
|
27 profile: "profile1" |
|
28 }, |
|
29 { uri: "data:text/html,<html><head><title>Mozilla</title></head><body>Mozilla</body></html>", |
|
30 title: "Mozilla", |
|
31 profile: "profile1" |
|
32 }, |
|
33 { uri: "http://www.mozilla.com/en-US/firefox/sync/firstrun.html", |
|
34 title: "Firstrun", |
|
35 profile: "profile1" |
|
36 } |
|
37 ]; |
|
38 |
|
39 var tabs2 = [ |
|
40 { uri: "data:text/html,<html><head><title>Firefox</title></head><body>Firefox</body></html>", |
|
41 title: "Firefox", |
|
42 profile: "profile1" |
|
43 }, |
|
44 { uri: "data:text/html,<html><head><title>Mozilla</title></head><body>Mozilla</body></html>", |
|
45 title: "Mozilla", |
|
46 profile: "profile1" |
|
47 } |
|
48 ]; |
|
49 |
|
50 var tabs3 = [ |
|
51 { uri: "http://www.mozilla.com/en-US/firefox/sync/firstrun.html", |
|
52 title: "Firstrun", |
|
53 profile: "profile1" |
|
54 }, |
|
55 { uri: "about:plugins", |
|
56 title: "About", |
|
57 profile: "profile1" |
|
58 }, |
|
59 { uri: "about:credits", |
|
60 title: "Credits", |
|
61 profile: "profile1" |
|
62 } |
|
63 ]; |
|
64 |
|
65 /* |
|
66 * Test phases |
|
67 */ |
|
68 Phase('phase1', [ |
|
69 [Tabs.add, tabs1], |
|
70 [Sync] |
|
71 ]); |
|
72 |
|
73 Phase('phase2', [ |
|
74 [Sync], |
|
75 [Tabs.verify, tabs2], |
|
76 [Tabs.verifyNot, tabs3] |
|
77 ]); |
|
78 |