public void Build_WithUnsuccessfulReferral_ReturnsReferralFailureModel()
        {
            var builder = new ReferralResultBuilder(_mockPostcodeValidator.Object);

            _referralRequestResult.ItkSendSuccess = false;
            var result = builder.Build(_referralRequestResult);

            Assert.IsInstanceOf <ReferralFailureResultViewModel>(result);
        }
        public void Build_WithSuccessfulReferral_ReturnsReferralConfirmationModel()
        {
            var builder = new ReferralResultBuilder(_mockPostcodeValidator.Object);

            _referralRequestResult.ItkSendSuccess = true;
            var result = builder.Build(_referralRequestResult);

            Assert.IsInstanceOf <ReferralConfirmationResultViewModel>(result);
        }
        public void Build_WithSuccessfulEDReferral_ReturnsReferralConfirmationModel()
        {
            var builder = new ReferralResultBuilder(_mockPostcodeValidator.Object);

            _referralRequestResult.ItkSendSuccess = true;
            _referralRequestResult.OutcomeGroup   = OutcomeGroup.AccidentAndEmergency;
            var result = builder.Build(_referralRequestResult);

            Assert.IsInstanceOf <AccidentAndEmergencyReferralConfirmationResultViewModel>(result);
        }
        public void Build_WithDuplicateEDReferral_ReturnsDuplicateReferralModel()
        {
            var builder = new ReferralResultBuilder(_mockPostcodeValidator.Object);

            _referralRequestResult.ItkDuplicate = true;
            _referralRequestResult.OutcomeGroup = OutcomeGroup.AccidentAndEmergency;
            var result = builder.Build(_referralRequestResult);

            Assert.IsInstanceOf <DuplicateReferralResultViewModel>(result);
        }
        public void Build_WithDuplicateReferral_ReturnsDuplicateReferralModel()
        {
            var builder = new ReferralResultBuilder(_mockPostcodeValidator.Object);

            _referralRequestResult.ItkDuplicate = true;
            var result = builder.Build(_referralRequestResult);

            //Temporarily removed until status of Dupe bug is known https://trello.com/c/5hqJVLDv
            // Assert.IsInstanceOf<DuplicateReferralResultViewModel>(result);
            Assert.IsInstanceOf <ReferralConfirmationResultViewModel>(result);
        }