OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 // This file contains various mock objects for the chrome platform to make | 5 // This file contains various mock objects for the chrome platform to make |
6 // unit testing easier. | 6 // unit testing easier. |
7 | 7 |
8 Entry = function() {}; | 8 Entry = function() {}; |
9 | 9 |
10 var chromeMocks = {}; | 10 var chromeMocks = {}; |
(...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
196 if (!originals_) { | 196 if (!originals_) { |
197 throw new Error('You must call activate() before restore().'); | 197 throw new Error('You must call activate() before restore().'); |
198 } | 198 } |
199 for (var components in originals_) { | 199 for (var components in originals_) { |
200 chrome[components] = originals_[components]; | 200 chrome[components] = originals_[components]; |
201 } | 201 } |
202 originals_ = null; | 202 originals_ = null; |
203 }; | 203 }; |
204 | 204 |
205 })(); | 205 })(); |
OLD | NEW |