OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 <algorithm> | 5 #include <algorithm> |
6 #include <cstdint> | 6 #include <cstdint> |
7 #include <memory> | 7 #include <memory> |
8 #include <ostream> | 8 #include <ostream> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 QuicVersionVector supported_versions; | 84 QuicVersionVector supported_versions; |
85 }; | 85 }; |
86 | 86 |
87 // Constructs various test permutations. | 87 // Constructs various test permutations. |
88 vector<TestParams> GetTestParams() { | 88 vector<TestParams> GetTestParams() { |
89 vector<TestParams> params; | 89 vector<TestParams> params; |
90 static const bool kTrueFalse[] = {true, false}; | 90 static const bool kTrueFalse[] = {true, false}; |
91 for (bool enable_stateless_rejects : kTrueFalse) { | 91 for (bool enable_stateless_rejects : kTrueFalse) { |
92 for (bool use_stateless_rejects : kTrueFalse) { | 92 for (bool use_stateless_rejects : kTrueFalse) { |
93 // Start with all versions, remove highest on each iteration. | 93 // Start with all versions, remove highest on each iteration. |
94 QuicVersionVector supported_versions = QuicSupportedVersions(); | 94 QuicVersionVector supported_versions = AllSupportedVersions(); |
95 while (!supported_versions.empty()) { | 95 while (!supported_versions.empty()) { |
96 params.push_back(TestParams(enable_stateless_rejects, | 96 params.push_back(TestParams(enable_stateless_rejects, |
97 use_stateless_rejects, supported_versions)); | 97 use_stateless_rejects, supported_versions)); |
98 supported_versions.erase(supported_versions.begin()); | 98 supported_versions.erase(supported_versions.begin()); |
99 } | 99 } |
100 } | 100 } |
101 } | 101 } |
102 return params; | 102 return params; |
103 } | 103 } |
104 | 104 |
(...skipping 1138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1243 EXPECT_EQ(0, strike_register_client_->PendingVerifications()); | 1243 EXPECT_EQ(0, strike_register_client_->PendingVerifications()); |
1244 } else { | 1244 } else { |
1245 // version 33. | 1245 // version 33. |
1246 ASSERT_EQ(kSHLO, out_.tag()); | 1246 ASSERT_EQ(kSHLO, out_.tag()); |
1247 CheckServerHello(out_); | 1247 CheckServerHello(out_); |
1248 } | 1248 } |
1249 } | 1249 } |
1250 | 1250 |
1251 } // namespace test | 1251 } // namespace test |
1252 } // namespace net | 1252 } // namespace net |
OLD | NEW |