diff options
author | ncteisen <ncteisen@gmail.com> | 2018-03-16 08:42:08 -0700 |
---|---|---|
committer | ncteisen <ncteisen@gmail.com> | 2018-03-16 08:42:08 -0700 |
commit | 613d6327efeced1bea3baba1c19b2f287d4cb53e (patch) | |
tree | c195d1c9ca151e5eb2191d931bd73cea0faa8471 /test | |
parent | 2352380262692c9a418112bea615fd51934e2635 (diff) |
Add more validation tests to channel_trace_test
Diffstat (limited to 'test')
-rw-r--r-- | test/core/channel/channel_trace_test.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/core/channel/channel_trace_test.cc b/test/core/channel/channel_trace_test.cc index 0ba13ff136..3c73e33612 100644 --- a/test/core/channel/channel_trace_test.cc +++ b/test/core/channel/channel_trace_test.cc @@ -189,19 +189,24 @@ TEST_P(ChannelTracerTest, TestNesting) { RefCountedPtr<ChannelTrace> tracer = MakeRefCounted<ChannelTrace>(GetParam()); AddSimpleTrace(tracer); AddSimpleTrace(tracer); + ValidateChannelTrace(tracer, 2, GetParam()); RefCountedPtr<ChannelTrace> sc1 = MakeRefCounted<ChannelTrace>(GetParam()); tracer->AddTraceEventReferencingChannel( ChannelTrace::Severity::Info, grpc_slice_from_static_string("subchannel one created"), sc1); + ValidateChannelTrace(tracer, 3, GetParam()); AddSimpleTrace(sc1); RefCountedPtr<ChannelTrace> conn1 = MakeRefCounted<ChannelTrace>(GetParam()); // nesting one level deeper. sc1->AddTraceEventReferencingSubchannel( ChannelTrace::Severity::Info, grpc_slice_from_static_string("connection one created"), conn1); + ValidateChannelTrace(tracer, 3, GetParam()); AddSimpleTrace(conn1); AddSimpleTrace(tracer); AddSimpleTrace(tracer); + ValidateChannelTrace(tracer, 5, GetParam()); + ValidateChannelTrace(conn1, 1, GetParam()); RefCountedPtr<ChannelTrace> sc2 = MakeRefCounted<ChannelTrace>(GetParam()); tracer->AddTraceEventReferencingSubchannel( ChannelTrace::Severity::Info, @@ -212,6 +217,7 @@ TEST_P(ChannelTracerTest, TestNesting) { ChannelTrace::Severity::Warning, grpc_slice_from_static_string("subchannel one inactive"), sc1); AddSimpleTrace(tracer); + ValidateChannelTrace(tracer, 8, GetParam()); tracer.reset(nullptr); sc1.reset(nullptr); sc2.reset(nullptr); |