CSR-1452 | Unit test fix
This commit is contained in:
parent
551c6b9a60
commit
c1d7585056
1 changed files with 14 additions and 0 deletions
|
|
@ -186,18 +186,21 @@ describe("shop-question.vue", () => {
|
|||
buttonLabel: "Westerville",
|
||||
buttonLabelSubCopy: "5 mi",
|
||||
value: "003335",
|
||||
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||
},
|
||||
{
|
||||
buttonBodyCopy: "760 Dearborn Park Ln, Worthington, OH 43085",
|
||||
buttonLabel: "Worthington",
|
||||
buttonLabelSubCopy: "10.5 mi",
|
||||
value: "001820",
|
||||
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||
},
|
||||
{
|
||||
buttonBodyCopy: "5015 N High St, Columbus, OH 43214",
|
||||
buttonLabel: "Columbus",
|
||||
buttonLabelSubCopy: "11.5 mi",
|
||||
value: "003343",
|
||||
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||
},
|
||||
]);
|
||||
});
|
||||
|
|
@ -414,6 +417,10 @@ describe("shop-question.vue", () => {
|
|||
},
|
||||
});
|
||||
|
||||
displayedAnswers.forEach(
|
||||
(answer) => (answer.additionalButtonData = wrapper.vm.additionalButtonData)
|
||||
);
|
||||
|
||||
// Act
|
||||
await wrapper.setProps({
|
||||
shopProviderData: shopQuestionInitialData,
|
||||
|
|
@ -445,42 +452,49 @@ describe("shop-question.vue", () => {
|
|||
|
||||
// Assert
|
||||
expect(wrapper.vm.answers.length).toBe(6);
|
||||
console.log(wrapper.vm.answers);
|
||||
expect(wrapper.vm.answers).toEqual([
|
||||
{
|
||||
buttonBodyCopy: "4403 Executive Pkwy, Westerville, OH 43081",
|
||||
buttonLabel: "Westerville",
|
||||
buttonLabelSubCopy: "5 mi",
|
||||
value: "003335",
|
||||
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||
},
|
||||
{
|
||||
buttonBodyCopy: "760 Dearborn Park Ln, Worthington, OH 43085",
|
||||
buttonLabel: "Worthington",
|
||||
buttonLabelSubCopy: "10.5 mi",
|
||||
value: "001820",
|
||||
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||
},
|
||||
{
|
||||
buttonBodyCopy: "5015 N High St, Columbus, OH 43214",
|
||||
buttonLabel: "Columbus",
|
||||
buttonLabelSubCopy: "11.5 mi",
|
||||
value: "003343",
|
||||
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||
},
|
||||
{
|
||||
buttonBodyCopy: "1670 Harmon Ave, Columbus, OH 43223",
|
||||
buttonLabel: "Columbus",
|
||||
buttonLabelSubCopy: "16 mi",
|
||||
value: "006747",
|
||||
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||
},
|
||||
{
|
||||
buttonBodyCopy: "3938 Powell Rd, Powell, OH 43065",
|
||||
buttonLabel: "Powell",
|
||||
buttonLabelSubCopy: "16.5 mi",
|
||||
value: "003341",
|
||||
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||
},
|
||||
{
|
||||
buttonBodyCopy: "4580 W Broad St, Columbus, OH 43228",
|
||||
buttonLabel: "Columbus",
|
||||
buttonLabelSubCopy: "19.5 mi",
|
||||
value: "003342",
|
||||
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||
},
|
||||
]);
|
||||
});
|
||||
|
|
|
|||
Loading…
Reference in a new issue