| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2012 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. | |
| 4 | |
| 5 var assertEq = chrome.test.assertEq; | |
| 6 var pass = chrome.test.callbackPass; | |
| 7 | |
| 8 chrome.test.runTests([ | |
| 9 function getAuthToken() { | |
| 10 chrome.experimental.identity.getAuthToken( | |
| 11 pass(function(token) { | |
| 12 assertEq('auth_token', token); | |
| 13 })); | |
| 14 }, | |
| 15 | |
| 16 function launchAuthFlow() { | |
| 17 chrome.experimental.identity.launchWebAuthFlow( | |
| 18 {url: 'https://some/url'}, | |
| 19 pass(function(url) { | |
| 20 assertEq('https://abcd.chromiumapp.org/cb#access_token=tok', url); | |
| 21 })); | |
| 22 } | |
| 23 ]); | |
| OLD | NEW |