コード例 #1
0
        private void Validate(SnsMessage <TLambdaParameter> message)
        {
            Logger.LogInformation("Beginning sns request validation.");
            Stopwatch.Restart();

            Lambda.Validate(message);

            Stopwatch.Stop();
            Logger.LogInformation("Finished request validation in {time} ms", Stopwatch.ElapsedMilliseconds);
        }
コード例 #2
0
            public void ShouldSerializeInsideSnsMessage(
                string stackId,
                string clientRequestToken,
                SnsMessage <CloudFormationStackEvent> message
                )
            {
                var serialized   = JsonSerializer.Serialize(message);
                var deserialized = JsonSerializer.Deserialize <SnsMessage <CloudFormationStackEvent> >(serialized);

                deserialized !.Message.StackId.Should().Be(message.Message.StackId);
            }
コード例 #3
0
 public static SnsMessage <TestLambdaMessage> Matches(SnsMessage <TestLambdaMessage> givenMessage)
 {
     return(Is <SnsMessage <TestLambdaMessage> >(message =>
                                                 message.Message.Id == givenMessage.Message.Id
                                                 ));
 }