1 // Copyright 2023 gRPC authors.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14
15 #include "absl/random/random.h"
16
17 #include "src/core/lib/debug/trace.h"
18 #include "test/core/transport/test_suite/fixture.h"
19 #include "test/core/transport/test_suite/test.h"
20 #include "test/core/util/test_config.h"
21
main(int argc,char ** argv)22 int main(int argc, char** argv) {
23 grpc::testing::TestEnvironment env(&argc, argv);
24 absl::BitGen bitgen;
25 ::testing::InitGoogleTest(&argc, argv);
26 for (const auto& test : grpc_core::TransportTestRegistry::Get().tests()) {
27 for (const auto& fixture :
28 grpc_core::TransportFixtureRegistry::Get().fixtures()) {
29 ::testing::RegisterTest(
30 "TransportTest", absl::StrCat(test.name, "/", fixture.name).c_str(),
31 nullptr, nullptr, __FILE__, __LINE__,
32 [test = &test, fixture = &fixture,
33 &bitgen]() -> grpc_core::TransportTest* {
34 return test->create(
35 std::unique_ptr<grpc_core::TransportFixture>(fixture->create()),
36 fuzzing_event_engine::Actions(), bitgen);
37 });
38 }
39 }
40 grpc_tracer_init();
41 return RUN_ALL_TESTS();
42 }
43