OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #include <string> | 5 #include <string> |
6 | 6 |
7 #include "base/memory/ref_counted.h" | 7 #include "base/memory/ref_counted.h" |
8 #include "base/memory/scoped_temp_dir.h" | |
9 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
10 #include "base/message_loop_proxy.h" | 9 #include "base/message_loop_proxy.h" |
| 10 #include "base/scoped_temp_dir.h" |
11 #include "base/string_util.h" | 11 #include "base/string_util.h" |
12 #include "remoting/host/host_key_pair.h" | 12 #include "remoting/host/host_key_pair.h" |
13 #include "remoting/host/json_host_config.h" | 13 #include "remoting/host/json_host_config.h" |
14 #include "remoting/host/test_key_pair.h" | 14 #include "remoting/host/test_key_pair.h" |
15 #include "testing/gmock/include/gmock/gmock.h" | 15 #include "testing/gmock/include/gmock/gmock.h" |
16 #include "testing/gtest/include/gtest/gtest.h" | 16 #include "testing/gtest/include/gtest/gtest.h" |
17 | 17 |
18 namespace remoting { | 18 namespace remoting { |
19 | 19 |
20 namespace { | 20 namespace { |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 TEST_F(HostKeyPairTest, Signatures) { | 63 TEST_F(HostKeyPairTest, Signatures) { |
64 // Sign a message and check that we get expected signature. | 64 // Sign a message and check that we get expected signature. |
65 HostKeyPair key_pair; | 65 HostKeyPair key_pair; |
66 key_pair.LoadFromString(kTestHostKeyPair); | 66 key_pair.LoadFromString(kTestHostKeyPair); |
67 | 67 |
68 std::string signature_base64 = key_pair.GetSignature(kTestMessage); | 68 std::string signature_base64 = key_pair.GetSignature(kTestMessage); |
69 ASSERT_EQ(signature_base64, std::string(kExpectedSignature)); | 69 ASSERT_EQ(signature_base64, std::string(kExpectedSignature)); |
70 } | 70 } |
71 | 71 |
72 } // namespace remoting | 72 } // namespace remoting |
OLD | NEW |