| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chrome/test/chromedriver/commands.h" | 5 #include "chrome/test/chromedriver/commands.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <list> | 10 #include <list> |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 const Status& status, | 85 const Status& status, |
| 86 std::unique_ptr<base::Value> value, | 86 std::unique_ptr<base::Value> value, |
| 87 const std::string& session_id, | 87 const std::string& session_id, |
| 88 bool w3c_compliant) { | 88 bool w3c_compliant) { |
| 89 if (!session_remaining_count) | 89 if (!session_remaining_count) |
| 90 return; | 90 return; |
| 91 | 91 |
| 92 (*session_remaining_count)--; | 92 (*session_remaining_count)--; |
| 93 | 93 |
| 94 std::unique_ptr<base::DictionaryValue> session(new base::DictionaryValue()); | 94 std::unique_ptr<base::DictionaryValue> session(new base::DictionaryValue()); |
| 95 session->Set("id", new base::StringValue(session_id)); | 95 session->Set("id", new base::Value(session_id)); |
| 96 session->Set("capabilities", value->DeepCopy()); | 96 session->Set("capabilities", value->DeepCopy()); |
| 97 session_list->Append(std::move(session)); | 97 session_list->Append(std::move(session)); |
| 98 | 98 |
| 99 if (!*session_remaining_count) { | 99 if (!*session_remaining_count) { |
| 100 all_get_session_func.Run(); | 100 all_get_session_func.Run(); |
| 101 } | 101 } |
| 102 } | 102 } |
| 103 | 103 |
| 104 } // namespace | 104 } // namespace |
| 105 | 105 |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 325 } | 325 } |
| 326 } | 326 } |
| 327 | 327 |
| 328 namespace internal { | 328 namespace internal { |
| 329 | 329 |
| 330 void CreateSessionOnSessionThreadForTesting(const std::string& id) { | 330 void CreateSessionOnSessionThreadForTesting(const std::string& id) { |
| 331 SetThreadLocalSession(base::MakeUnique<Session>(id)); | 331 SetThreadLocalSession(base::MakeUnique<Session>(id)); |
| 332 } | 332 } |
| 333 | 333 |
| 334 } // namespace internal | 334 } // namespace internal |
| OLD | NEW |