forked from envoyproxy/envoy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathxds_integration_test.cc
41 lines (34 loc) · 1.35 KB
/
xds_integration_test.cc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#include "test/integration/http_integration.h"
#include "test/test_common/utility.h"
#include "gtest/gtest.h"
namespace Envoy {
namespace {
// This is a minimal litmus test for the v2 xDS APIs.
class XdsIntegrationTest : public HttpIntegrationTest,
public testing::TestWithParam<Network::Address::IpVersion> {
public:
XdsIntegrationTest()
: HttpIntegrationTest(Http::CodecClient::Type::HTTP2, GetParam(), realTime()) {
setUpstreamProtocol(FakeHttpConnection::Type::HTTP2);
}
void createEnvoy() override {
registerPort("upstream_0", fake_upstreams_.back()->localAddress()->ip()->port());
createApiTestServer(
{
"test/config/integration/server_xds.bootstrap.yaml",
"test/config/integration/server_xds.cds.yaml",
"test/config/integration/server_xds.eds.yaml",
"test/config/integration/server_xds.lds.yaml",
"test/config/integration/server_xds.rds.yaml",
},
{"http"});
}
};
INSTANTIATE_TEST_CASE_P(IpVersions, XdsIntegrationTest,
testing::ValuesIn(TestEnvironment::getIpVersionsForTest()),
TestUtility::ipTestParamsToString);
TEST_P(XdsIntegrationTest, RouterRequestAndResponseWithBodyNoBuffer) {
testRouterRequestAndResponseWithBody(1024, 512, false);
}
} // namespace
} // namespace Envoy