1 // Copyright 2014 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.
5 var error = "The alphaEnabled option requires dev channel or newer.";
7 function testAlphaEnabled(testId, setValue) {
8 var createOptions = { frame: 'none' };
9 createOptions.alphaEnabled = setValue;
11 chrome.app.window.create('index.html',
13 chrome.test.callbackFail(error));
16 // All these tests are run in Stable channel with app.window.alpha
19 chrome.app.runtime.onLaunched.addListener(function() {
20 chrome.test.runTests([
22 // Window is created with alphaEnabled set to true.
23 function testAlphaEnabledStableInitTrue() {
24 testAlphaEnabled('testAlphaEnabledStableInitTrue', true);
27 // Window is created with alphaEnabled set to false.
28 function testAlphaEnabledStableInitFalse() {
29 testAlphaEnabled('testAlphaEnabledStableInitFalse', false);