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

Unified Diff: chrome/browser/internal_auth_unittest.cc

Issue 6683060: Private API for extensions like ssh-client that need access to TCP. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix Created 9 years, 9 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
Index: chrome/browser/internal_auth_unittest.cc
diff --git a/chrome/browser/internal_auth_unittest.cc b/chrome/browser/internal_auth_unittest.cc
new file mode 100644
index 0000000000000000000000000000000000000000..d3c51153c9599bca3c35886d8c3f026a322169cd
--- /dev/null
+++ b/chrome/browser/internal_auth_unittest.cc
@@ -0,0 +1,16 @@
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "chrome/browser/internal_auth.h"
+
+#include "testing/gtest/include/gtest/gtest.h"
+
+TEST(InternalAuth, BasicGeneration) {
+ std::vector<std::string> var_value_list;
+ var_value_list.push_back("key=value");
+ std::string token = browser::InternalAuthGeneration::GenerateToken(
+ "zapata", var_value_list);
+ ASSERT_GT(token.size(), 10); // short token is unsecure.
+}
+

Powered by Google App Engine
This is Rietveld 408576698