예제 #1
0
        public void StartCreatingAccount_WhenCalled_ReturnsPartialViewResultWhereModelIsAccountingIdentificationViewModel()
        {
            Controller sut = CreateSut();

            PartialViewResult result = (PartialViewResult)sut.StartCreatingAccount(_fixture.Create <int>());

            Assert.That(result.Model, Is.TypeOf <AccountingIdentificationViewModel>());
        }
예제 #2
0
        public void StartCreatingAccount_WhenCalled_ReturnsPartialViewResultWhereModelIsNotNull()
        {
            Controller sut = CreateSut();

            PartialViewResult result = (PartialViewResult)sut.StartCreatingAccount(_fixture.Create <int>());

            Assert.That(result.Model, Is.Not.Null);
        }
예제 #3
0
        public void StartCreatingAccount_WhenCalled_ReturnsPartialViewResultWhereViewNameIsEqualToCreatingAccountPartial()
        {
            Controller sut = CreateSut();

            PartialViewResult result = (PartialViewResult)sut.StartCreatingAccount(_fixture.Create <int>());

            Assert.That(result.ViewName, Is.EqualTo("_CreatingAccountPartial"));
        }
예제 #4
0
        public void StartCreatingAccount_WhenCalled_ReturnsPartialViewResult()
        {
            Controller sut = CreateSut();

            IActionResult result = sut.StartCreatingAccount(_fixture.Create <int>());

            Assert.That(result, Is.TypeOf <PartialViewResult>());
        }
예제 #5
0
        public void StartCreatingAccount_WhenCalled_ReturnsNotNull()
        {
            Controller sut = CreateSut();

            IActionResult result = sut.StartCreatingAccount(_fixture.Create <int>());

            Assert.That(result, Is.Not.Null);
        }
예제 #6
0
        public void StartCreatingAccount_WhenCalled_ReturnsPartialViewResultWhereModelIsAccountingIdentificationViewModelWithAccountingNumberEqualToArgument()
        {
            Controller sut = CreateSut();

            int accountingNumber     = _fixture.Create <int>();
            PartialViewResult result = (PartialViewResult)sut.StartCreatingAccount(accountingNumber);

            AccountingIdentificationViewModel accountingIdentificationViewModel = (AccountingIdentificationViewModel)result.Model;

            Assert.That(accountingIdentificationViewModel.AccountingNumber, Is.EqualTo(accountingNumber));
        }