diff options
Diffstat (limited to 'android_webview/javatests')
-rw-r--r-- | android_webview/javatests/src/org/chromium/android_webview/test/AwSettingsTest.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/android_webview/javatests/src/org/chromium/android_webview/test/AwSettingsTest.java b/android_webview/javatests/src/org/chromium/android_webview/test/AwSettingsTest.java index d2ced4e..c3d575d 100644 --- a/android_webview/javatests/src/org/chromium/android_webview/test/AwSettingsTest.java +++ b/android_webview/javatests/src/org/chromium/android_webview/test/AwSettingsTest.java @@ -1504,10 +1504,12 @@ public class AwSettingsTest extends AwTestBase { final AwContents awContents = testContainerView.getAwContents(); AwSettings settings = getAwSettingsOnUiThread(awContents); final String actualUserAgentString = settings.getUserAgentString(); + assertEquals(actualUserAgentString, AwSettings.getDefaultUserAgent()); final String patternString = "Mozilla/5\\.0 \\(Linux;( U;)? Android ([^;]+);( (\\w+)-(\\w+);)?" + "\\s?(.*)\\sBuild/(.+)\\) AppleWebKit/(\\d+)\\.(\\d+) \\(KHTML, like Gecko\\) " + - "Version/\\d+\\.\\d+( Mobile)? Safari/(\\d+)\\.(\\d+)"; + "Version/\\d+\\.\\d Chrome/\\d+\\.\\d+\\.\\d+\\.\\d+" + + "( Mobile)? Safari/(\\d+)\\.(\\d+)"; final Pattern userAgentExpr = Pattern.compile(patternString); Matcher patternMatcher = userAgentExpr.matcher(actualUserAgentString); assertTrue(String.format("User agent string did not match expected pattern. %nExpected " + |