| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Mocks for globals needed for loading background.js. | 5 // Mocks for globals needed for loading background.js. |
| 6 | 6 |
| 7 function emptyMock() {} | 7 function emptyMock() {} |
| 8 function buildTaskManager() { | 8 function buildTaskManager() { |
| 9 return {instrumentApiFunction: emptyMock}; | 9 return { |
| 10 debugSetStepName: emptyMock, |
| 11 instrumentApiFunction: emptyMock, |
| 12 }; |
| 10 } | 13 } |
| 11 var instrumentApiFunction = emptyMock; | 14 var instrumentApiFunction = emptyMock; |
| 12 var buildAttemptManager = emptyMock; | 15 var buildAttemptManager = emptyMock; |
| 13 var buildCardSet = emptyMock; | 16 var buildCardSet = emptyMock; |
| 14 var emptyListener = {addListener: emptyMock}; | 17 var emptyListener = {addListener: emptyMock}; |
| 15 chrome['location'] = {onLocationUpdate: emptyListener}; | 18 chrome['location'] = {onLocationUpdate: emptyListener}; |
| 16 chrome['notifications'] = { | 19 chrome['notifications'] = { |
| 17 onButtonClicked: emptyListener, | 20 onButtonClicked: emptyListener, |
| 18 onClicked: emptyListener, | 21 onClicked: emptyListener, |
| 19 onClosed: emptyListener | 22 onClosed: emptyListener |
| 20 }; | 23 }; |
| 21 chrome['omnibox'] = {onInputEntered: emptyListener}; | 24 chrome['omnibox'] = {onInputEntered: emptyListener}; |
| 25 chrome['preferencesPrivate'] = { |
| 26 googleGeolocationAccessEnabled: { |
| 27 onChange: emptyListener |
| 28 } |
| 29 }; |
| 22 chrome['runtime'] = { | 30 chrome['runtime'] = { |
| 23 onInstalled: emptyListener, | 31 onInstalled: emptyListener, |
| 24 onStartup: emptyListener | 32 onStartup: emptyListener |
| 25 }; | 33 }; |
| 26 | 34 |
| 27 var storage = {}; | 35 var storage = {}; |
| OLD | NEW |