| Index: net/proxy/proxy_resolver_v8_unittest.cc
|
| ===================================================================
|
| --- net/proxy/proxy_resolver_v8_unittest.cc (revision 26789)
|
| +++ net/proxy/proxy_resolver_v8_unittest.cc (working copy)
|
| @@ -420,5 +420,23 @@
|
| LoadLog::PHASE_END);
|
| }
|
|
|
| +// Try loading a PAC script which ends with a trailing comment (no terminal
|
| +// newline). This should not cause problems with the PAC utility functions
|
| +// that we add to the script.
|
| +// http://crbug.com/22864
|
| +TEST(ProxyResolverV8Test, TrailingComment) {
|
| + ProxyResolverV8WithMockBindings resolver;
|
| + int result = resolver.SetPacScriptFromDisk("ends_with_comment.js");
|
| + EXPECT_EQ(OK, result);
|
| +
|
| + ProxyInfo proxy_info;
|
| + scoped_refptr<LoadLog> log(new LoadLog);
|
| + result = resolver.GetProxyForURL(kQueryUrl, &proxy_info, NULL, NULL, log);
|
| +
|
| + EXPECT_EQ(OK, result);
|
| + EXPECT_FALSE(proxy_info.is_direct());
|
| + EXPECT_EQ("success:80", proxy_info.proxy_server().ToURI());
|
| +}
|
| +
|
| } // namespace
|
| } // namespace net
|
|
|