Пример #1
0
        public void ThrowBadRequestIfNull_ArgumentException(string message)
        {
            // Arrange
            Entity.Parcel parcel = null;

            // Act
            // Assert
            Assert.Throws <ArgumentException>(() => parcel.ThrowBadRequestIfNull(message));
        }
Пример #2
0
        public void ThrowBadRequestIfNull_WithNull()
        {
            // Arrange
            Entity.Parcel parcel = null;

            // Act
            // Assert
            Assert.Throws <BadRequestException>(() => parcel.ThrowBadRequestIfNull("test"));
        }
Пример #3
0
        public void ThrowBadRequestIfNull_WithObject()
        {
            // Arrange
            var parcel = new Entity.Parcel();

            // Act
            parcel.ThrowBadRequestIfNull("test");

            // Assert
            Assert.NotNull(parcel);
        }