1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
6 * @type {Array<{key: string,
7 * type: chrome.settingsPrivate.PrefType,
9 * Test cases containing preference data. Each pref has three test values,
10 * which can be used to change the pref. Intentionally, for a given pref, not
11 * every test value is different from the one before it; this tests what
12 * happens when stale changes are reported.
14 var prefsTestCases
= [{
15 key
: 'top_level_pref',
16 type
: chrome
.settingsPrivate
.PrefType
.BOOLEAN
,
17 values
: [true, false, true],
19 key
: 'browser.enable_flash',
20 type
: chrome
.settingsPrivate
.PrefType
.BOOLEAN
,
21 values
: [false, true, false],
23 key
: 'browser.enable_html5',
24 type
: chrome
.settingsPrivate
.PrefType
.BOOLEAN
,
25 values
: [true, false, false],
27 key
: 'device.overclock',
28 type
: chrome
.settingsPrivate
.PrefType
.NUMBER
,
31 key
: 'browser.on.startup.homepage',
32 type
: chrome
.settingsPrivate
.PrefType
.STRING
,
33 values
: ['example.com', 'chromium.org', 'chrome.example.com'],
36 type
: chrome
.settingsPrivate
.PrefType
.STRING
,
37 values
: ['Puppy', 'Puppy', 'Horsey'],
40 type
: chrome
.settingsPrivate
.PrefType
.LIST
,
41 // Arrays of dictionaries.
43 [{javascript
: ['chromium.org', 'example.com'],
44 cookies
: ['example.net'],
50 [{javascript
: ['example.com', 'example.net'],
51 cookies
: ['example.net', 'example.com'],
52 mic
: ['example.com']},
56 [{javascript
: ['chromium.org', 'example.com'],
57 cookies
: ['chromium.org', 'example.net', 'example.com'],
59 mic
: ['example.com']},