Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(95)

Unified Diff: net/http/http_auth_handler_negotiate_unittest.cc

Issue 3040016: Net: Convert username and password to string16. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: address comments Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/http/http_auth_handler_negotiate.cc ('k') | net/http/http_auth_handler_ntlm.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_auth_handler_negotiate_unittest.cc
===================================================================
--- net/http/http_auth_handler_negotiate_unittest.cc (revision 53997)
+++ net/http/http_auth_handler_negotiate_unittest.cc (working copy)
@@ -4,6 +4,7 @@
#include "net/http/http_auth_handler_negotiate.h"
+#include "base/string_util.h"
#include "net/base/mock_host_resolver.h"
#include "net/base/net_errors.h"
#include "net/base/test_completion_callback.h"
@@ -225,8 +226,8 @@
TestCompletionCallback callback;
HttpRequestInfo request_info;
std::string token;
- std::wstring username = L"foo";
- std::wstring password = L"bar";
+ string16 username = ASCIIToUTF16("foo");
+ string16 password = ASCIIToUTF16("bar");
EXPECT_EQ(OK, auth_handler->GenerateAuthToken(&username, &password,
&request_info,
&callback, &token));
@@ -246,8 +247,8 @@
TestCompletionCallback callback;
HttpRequestInfo request_info;
std::string token;
- std::wstring username = L"foo";
- std::wstring password = L"bar";
+ string16 username = ASCIIToUTF16("foo");
+ string16 password = ASCIIToUTF16("bar");
EXPECT_EQ(OK, auth_handler->GenerateAuthToken(&username, &password,
&request_info,
&callback, &token));
@@ -267,8 +268,8 @@
TestCompletionCallback callback;
HttpRequestInfo request_info;
std::string token;
- std::wstring username = L"foo";
- std::wstring password = L"bar";
+ string16 username = ASCIIToUTF16("foo");
+ string16 password = ASCIIToUTF16("bar");
EXPECT_EQ(OK, auth_handler->GenerateAuthToken(&username, &password,
&request_info,
&callback, &token));
@@ -288,8 +289,8 @@
TestCompletionCallback callback;
HttpRequestInfo request_info;
std::string token;
- std::wstring username = L"foo";
- std::wstring password = L"bar";
+ string16 username = ASCIIToUTF16("foo");
+ string16 password = ASCIIToUTF16("bar");
EXPECT_EQ(OK, auth_handler->GenerateAuthToken(&username, &password,
&request_info,
&callback, &token));
@@ -309,8 +310,8 @@
TestCompletionCallback callback;
HttpRequestInfo request_info;
std::string token;
- std::wstring username = L"foo";
- std::wstring password = L"bar";
+ string16 username = ASCIIToUTF16("foo");
+ string16 password = ASCIIToUTF16("bar");
EXPECT_EQ(ERR_IO_PENDING, auth_handler->GenerateAuthToken(
&username, &password, &request_info, &callback, &token));
EXPECT_EQ(OK, callback.WaitForResult());
« no previous file with comments | « net/http/http_auth_handler_negotiate.cc ('k') | net/http/http_auth_handler_ntlm.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698