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 "chrome/test/webdriver/commands/webdriver_command.h" | 5 #include "chrome/test/webdriver/commands/webdriver_command.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 28 matching lines...) Expand all Loading... |
39 response->SetError( | 39 response->SetError( |
40 new Error(kSessionNotFound, "Session not found: " + session_id)); | 40 new Error(kSessionNotFound, "Session not found: " + session_id)); |
41 return false; | 41 return false; |
42 } | 42 } |
43 | 43 |
44 Error* error = session_->BeforeExecuteCommand(); | 44 Error* error = session_->BeforeExecuteCommand(); |
45 if (error) { | 45 if (error) { |
46 response->SetError(error); | 46 response->SetError(error); |
47 return false; | 47 return false; |
48 } | 48 } |
49 response->SetField("sessionId", Value::CreateStringValue(session_id)); | 49 response->SetField("sessionId", base::StringValue::New(session_id)); |
50 return true; | 50 return true; |
51 } | 51 } |
52 | 52 |
53 } // namespace webdriver | 53 } // namespace webdriver |
OLD | NEW |