コード例 #1
0
        private void FullFwAssertValid(TransactionDto transaction)
        {
            transaction.Should().NotBeNull();

            if (transaction.Context != null)
            {
                FullFwAssertValid(transaction.Context, transaction);
            }
            transaction.Name.Should().NotBeNull();
            TransactionResultFullFwAssertValid(transaction.Result);
            transaction.Type.Should().Be(ApiConstants.TypeRequest);
            FullFwAssertValid(transaction.SpanCount);
        }
コード例 #2
0
        public static void AssertStateIsValid(this TransactionDto transaction)
        {
            transaction.Should().NotBeNull();

            transaction.Id.Should().NotBeEmpty();

            (transaction.Currency.Amount >= decimal.Zero).Should().BeTrue();

            transaction.Currency.Type.Should().NotBeNull();

            transaction.Type.Should().NotBeNull();

            transaction.Description.Should().NotBeNullOrEmpty();
        }