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 package org.chromium.android_webview.test; | 5 package org.chromium.android_webview.test; |
6 | 6 |
7 import android.content.Context; | 7 import android.content.Context; |
8 import android.test.suitebuilder.annotation.MediumTest; | 8 import android.test.suitebuilder.annotation.MediumTest; |
9 import android.test.suitebuilder.annotation.SmallTest; | 9 import android.test.suitebuilder.annotation.SmallTest; |
10 import android.webkit.GeolocationPermissions; | 10 import android.webkit.GeolocationPermissions; |
11 | 11 |
12 import org.chromium.android_webview.AwContents; | 12 import org.chromium.android_webview.AwContents; |
13 import org.chromium.android_webview.AwSettings; | 13 import org.chromium.android_webview.AwSettings; |
14 import org.chromium.base.annotations.SuppressFBWarnings; | 14 import org.chromium.base.annotations.SuppressFBWarnings; |
15 import org.chromium.base.test.util.Feature; | 15 import org.chromium.base.test.util.Feature; |
16 import org.chromium.content.browser.LocationProviderFactory; | 16 import org.chromium.device.geolocation.LocationProviderFactory; |
17 import org.chromium.content.browser.test.util.MockLocationProvider; | 17 import org.chromium.device.geolocation.MockLocationProvider; |
18 | 18 |
19 import java.util.concurrent.Callable; | 19 import java.util.concurrent.Callable; |
20 | 20 |
21 /** | 21 /** |
22 * Test suite for Geolocation in AwContents. Smoke tests for | 22 * Test suite for Geolocation in AwContents. Smoke tests for |
23 * basic functionality, and tests to ensure the AwContents.onPause | 23 * basic functionality, and tests to ensure the AwContents.onPause |
24 * and onResume APIs affect Geolocation as expected. | 24 * and onResume APIs affect Geolocation as expected. |
25 */ | 25 */ |
26 public class GeolocationTest extends AwTestBase { | 26 public class GeolocationTest extends AwTestBase { |
27 private TestAwContentsClient mContentsClient; | 27 private TestAwContentsClient mContentsClient; |
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
350 | 350 |
351 pollInstrumentationThread(new Callable<Boolean>() { | 351 pollInstrumentationThread(new Callable<Boolean>() { |
352 @Override | 352 @Override |
353 public Boolean call() throws Exception { | 353 public Boolean call() throws Exception { |
354 return getPositionCountFromJS() > 0; | 354 return getPositionCountFromJS() > 0; |
355 } | 355 } |
356 }); | 356 }); |
357 } | 357 } |
358 | 358 |
359 } | 359 } |
OLD | NEW |