コード例 #1
0
            public void DeliveryTimeNotSpecifiedGivesFalse()
            {
                //Arrange
                var message = new Message(Sender, DomainUtility.GetRecipientByDigipostId(), DomainUtility.GetDocument()
                                          );

                //Act

                //Assert
                Assert.False(message.DeliveryTimeSpecified);
            }
コード例 #2
0
            public void ConstructWithRecipientAndPrimaryDocument()
            {
                //Arrange
                var message = new Message(Sender, DomainUtility.GetRecipientByDigipostId(), DomainUtility.GetDocument()
                                          );

                //Act

                //Assert
                Assert.NotNull(message.PrimaryDocument);
            }
コード例 #3
0
            public void DeliveryTimeSpecifiedGivesTrue()
            {
                //Arrange
                var message = new Message(Sender, DomainUtility.GetRecipientByDigipostId(), DomainUtility.GetDocument()
                                          )
                {
                    DeliveryTime = DateTime.Today
                };

                //Act

                //Assert
                Assert.True(message.DeliveryTimeSpecified);
            }
コード例 #4
0
            public void ConstructWithRecipientByIdAndPrintDetailsMethod()
            {
                //Arrange
                var recipient    = DomainUtility.GetRecipientByDigipostId();
                var document     = DomainUtility.GetDocument();
                var printDetails = DomainUtility.GetPrintDetails();

                var message = new Message(Sender, recipient, document)
                {
                    PrintDetails = printDetails
                };

                //Act

                //Assert
                Assert.Equal(recipient, message.DigipostRecipient);
                Assert.Equal(document, message.PrimaryDocument);
                Assert.Equal(printDetails, message.PrintDetails);
            }