コード例 #1
0
        public void Should_Get_ValidCommandName()
        {
            // Arrange
            var mediatRMock = new Mock <IMediator>();
            var sut         = new AddLoyaltyCommand(mediatRMock.Object);

            // Act // Assert
            Assert.Equal("add loyalty", sut.Name);
        }
コード例 #2
0
        public void Should_ReturnTrue_IsMatchResut()
        {
            // Arrange
            var mediatRMock = new Mock <IMediator>();
            var sut         = new AddLoyaltyCommand(mediatRMock.Object);
            // Act
            var result = sut.IsMatch("add loyalty");

            // Assert
            Assert.True(result);
        }