| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "components/proximity_auth/device_to_device_authenticator.h" | 5 #include "components/proximity_auth/device_to_device_authenticator.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/base64url.h" | 9 #include "base/base64url.h" |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 334 SendMessagesAfterAuthenticationSuccess) { | 334 SendMessagesAfterAuthenticationSuccess) { |
| 335 std::string hello_message = BeginAuthentication(); | 335 std::string hello_message = BeginAuthentication(); |
| 336 EXPECT_CALL(*this, | 336 EXPECT_CALL(*this, |
| 337 OnAuthenticationResultProxy(Authenticator::Result::SUCCESS)); | 337 OnAuthenticationResultProxy(Authenticator::Result::SUCCESS)); |
| 338 SimulateResponderAuth(hello_message); | 338 SimulateResponderAuth(hello_message); |
| 339 | 339 |
| 340 // Test that the authenticator is properly cleaned up after authentication | 340 // Test that the authenticator is properly cleaned up after authentication |
| 341 // completes. | 341 // completes. |
| 342 WireMessage wire_message(base::RandBytesAsString(300u)); | 342 WireMessage wire_message(base::RandBytesAsString(300u)); |
| 343 connection_.SendMessage( | 343 connection_.SendMessage( |
| 344 base::WrapUnique(new WireMessage(base::RandBytesAsString(300u)))); | 344 base::MakeUnique<WireMessage>(base::RandBytesAsString(300u))); |
| 345 connection_.OnBytesReceived(wire_message.Serialize()); | 345 connection_.OnBytesReceived(wire_message.Serialize()); |
| 346 connection_.SendMessage( | 346 connection_.SendMessage( |
| 347 base::WrapUnique(new WireMessage(base::RandBytesAsString(300u)))); | 347 base::MakeUnique<WireMessage>(base::RandBytesAsString(300u))); |
| 348 connection_.OnBytesReceived(wire_message.Serialize()); | 348 connection_.OnBytesReceived(wire_message.Serialize()); |
| 349 } | 349 } |
| 350 | 350 |
| 351 } // namespace proximity_auth | 351 } // namespace proximity_auth |
| OLD | NEW |