public void TestLogCategories(RpcLogCategory categoryToTest)
        {
            InboundGrpcEvent inboundEvent = new InboundGrpcEvent(Guid.NewGuid().ToString(), new Grpc.Messages.StreamingMessage
            {
                RpcLog = new Grpc.Messages.RpcLog
                {
                    LogCategory = categoryToTest,
                }
            });

            Assert.True(inboundEvent.IsLogOfCategory(categoryToTest));
        }
Exemple #2
0
 public static bool IsLogOfCategory(this InboundGrpcEvent inboundEvent, RpcLogCategory categoryToCheck)
 {
     return(inboundEvent.Message.RpcLog.LogCategory.Equals(categoryToCheck));
 }
Exemple #3
0
 public static bool IsMessageOfType(this InboundGrpcEvent inboundEvent, MessageType typeToCheck)
 {
     return(inboundEvent.MessageType.Equals(typeToCheck));
 }