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); }
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(); }