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

Side by Side Diff: third_party/WebKit/Source/modules/websockets/DOMWebSocketTest.cpp

Issue 2377253002: Add explicit to core/fetch, core/loader and modules/websockets (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 2 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 unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/core/loader/ThreadableLoaderTest.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "modules/websockets/DOMWebSocket.h" 5 #include "modules/websockets/DOMWebSocket.h"
6 6
7 #include "bindings/core/v8/ExceptionState.h" 7 #include "bindings/core/v8/ExceptionState.h"
8 #include "bindings/core/v8/V8Binding.h" 8 #include "bindings/core/v8/V8Binding.h"
9 #include "bindings/core/v8/V8BindingForTesting.h" 9 #include "bindings/core/v8/V8BindingForTesting.h"
10 #include "core/dom/DOMTypedArray.h" 10 #include "core/dom/DOMTypedArray.h"
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 return m_channel.get(); 94 return m_channel.get();
95 } 95 }
96 96
97 DEFINE_INLINE_VIRTUAL_TRACE() 97 DEFINE_INLINE_VIRTUAL_TRACE()
98 { 98 {
99 visitor->trace(m_channel); 99 visitor->trace(m_channel);
100 DOMWebSocket::trace(visitor); 100 DOMWebSocket::trace(visitor);
101 } 101 }
102 102
103 private: 103 private:
104 DOMWebSocketWithMockChannel(ExecutionContext* context) 104 explicit DOMWebSocketWithMockChannel(ExecutionContext* context)
105 : DOMWebSocket(context) 105 : DOMWebSocket(context)
106 , m_channel(MockWebSocketChannel::create()) 106 , m_channel(MockWebSocketChannel::create())
107 , m_hasCreatedChannel(false) { } 107 , m_hasCreatedChannel(false) { }
108 108
109 Member<MockWebSocketChannel> m_channel; 109 Member<MockWebSocketChannel> m_channel;
110 bool m_hasCreatedChannel; 110 bool m_hasCreatedChannel;
111 }; 111 };
112 112
113 class DOMWebSocketTestScope { 113 class DOMWebSocketTestScope {
114 public: 114 public:
(...skipping 694 matching lines...) Expand 10 before | Expand all | Expand 10 after
809 EXPECT_EQ(InvalidAccessError, scope.getExceptionState().code()); 809 EXPECT_EQ(InvalidAccessError, scope.getExceptionState().code());
810 EXPECT_EQ(String::format("The code must be either 1000, or between 3000 and 4999. %d is neither.", GetParam()), scope.getExceptionState().message()); 810 EXPECT_EQ(String::format("The code must be either 1000, or between 3000 and 4999. %d is neither.", GetParam()), scope.getExceptionState().message());
811 EXPECT_EQ(DOMWebSocket::kConnecting, webSocketScope.socket().readyState()); 811 EXPECT_EQ(DOMWebSocket::kConnecting, webSocketScope.socket().readyState());
812 } 812 }
813 813
814 INSTANTIATE_TEST_CASE_P(DOMWebSocketInvalidClosingCode, DOMWebSocketInvalidClosi ngCodeTest, ::testing::Values(0, 1, 998, 999, 1001, 2999, 5000, 9999, 65535)); 814 INSTANTIATE_TEST_CASE_P(DOMWebSocketInvalidClosingCode, DOMWebSocketInvalidClosi ngCodeTest, ::testing::Values(0, 1, 998, 999, 1001, 2999, 5000, 9999, 65535));
815 815
816 } // namespace 816 } // namespace
817 817
818 } // namespace blink 818 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/loader/ThreadableLoaderTest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698