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",
|
buttonLabel: "Westerville",
|
||||||
buttonLabelSubCopy: "5 mi",
|
buttonLabelSubCopy: "5 mi",
|
||||||
value: "003335",
|
value: "003335",
|
||||||
|
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
buttonBodyCopy: "760 Dearborn Park Ln, Worthington, OH 43085",
|
buttonBodyCopy: "760 Dearborn Park Ln, Worthington, OH 43085",
|
||||||
buttonLabel: "Worthington",
|
buttonLabel: "Worthington",
|
||||||
buttonLabelSubCopy: "10.5 mi",
|
buttonLabelSubCopy: "10.5 mi",
|
||||||
value: "001820",
|
value: "001820",
|
||||||
|
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
buttonBodyCopy: "5015 N High St, Columbus, OH 43214",
|
buttonBodyCopy: "5015 N High St, Columbus, OH 43214",
|
||||||
buttonLabel: "Columbus",
|
buttonLabel: "Columbus",
|
||||||
buttonLabelSubCopy: "11.5 mi",
|
buttonLabelSubCopy: "11.5 mi",
|
||||||
value: "003343",
|
value: "003343",
|
||||||
|
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
});
|
});
|
||||||
|
|
@ -414,6 +417,10 @@ describe("shop-question.vue", () => {
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
displayedAnswers.forEach(
|
||||||
|
(answer) => (answer.additionalButtonData = wrapper.vm.additionalButtonData)
|
||||||
|
);
|
||||||
|
|
||||||
// Act
|
// Act
|
||||||
await wrapper.setProps({
|
await wrapper.setProps({
|
||||||
shopProviderData: shopQuestionInitialData,
|
shopProviderData: shopQuestionInitialData,
|
||||||
|
|
@ -445,42 +452,49 @@ describe("shop-question.vue", () => {
|
||||||
|
|
||||||
// Assert
|
// Assert
|
||||||
expect(wrapper.vm.answers.length).toBe(6);
|
expect(wrapper.vm.answers.length).toBe(6);
|
||||||
|
console.log(wrapper.vm.answers);
|
||||||
expect(wrapper.vm.answers).toEqual([
|
expect(wrapper.vm.answers).toEqual([
|
||||||
{
|
{
|
||||||
buttonBodyCopy: "4403 Executive Pkwy, Westerville, OH 43081",
|
buttonBodyCopy: "4403 Executive Pkwy, Westerville, OH 43081",
|
||||||
buttonLabel: "Westerville",
|
buttonLabel: "Westerville",
|
||||||
buttonLabelSubCopy: "5 mi",
|
buttonLabelSubCopy: "5 mi",
|
||||||
value: "003335",
|
value: "003335",
|
||||||
|
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
buttonBodyCopy: "760 Dearborn Park Ln, Worthington, OH 43085",
|
buttonBodyCopy: "760 Dearborn Park Ln, Worthington, OH 43085",
|
||||||
buttonLabel: "Worthington",
|
buttonLabel: "Worthington",
|
||||||
buttonLabelSubCopy: "10.5 mi",
|
buttonLabelSubCopy: "10.5 mi",
|
||||||
value: "001820",
|
value: "001820",
|
||||||
|
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
buttonBodyCopy: "5015 N High St, Columbus, OH 43214",
|
buttonBodyCopy: "5015 N High St, Columbus, OH 43214",
|
||||||
buttonLabel: "Columbus",
|
buttonLabel: "Columbus",
|
||||||
buttonLabelSubCopy: "11.5 mi",
|
buttonLabelSubCopy: "11.5 mi",
|
||||||
value: "003343",
|
value: "003343",
|
||||||
|
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
buttonBodyCopy: "1670 Harmon Ave, Columbus, OH 43223",
|
buttonBodyCopy: "1670 Harmon Ave, Columbus, OH 43223",
|
||||||
buttonLabel: "Columbus",
|
buttonLabel: "Columbus",
|
||||||
buttonLabelSubCopy: "16 mi",
|
buttonLabelSubCopy: "16 mi",
|
||||||
value: "006747",
|
value: "006747",
|
||||||
|
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
buttonBodyCopy: "3938 Powell Rd, Powell, OH 43065",
|
buttonBodyCopy: "3938 Powell Rd, Powell, OH 43065",
|
||||||
buttonLabel: "Powell",
|
buttonLabel: "Powell",
|
||||||
buttonLabelSubCopy: "16.5 mi",
|
buttonLabelSubCopy: "16.5 mi",
|
||||||
value: "003341",
|
value: "003341",
|
||||||
|
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
buttonBodyCopy: "4580 W Broad St, Columbus, OH 43228",
|
buttonBodyCopy: "4580 W Broad St, Columbus, OH 43228",
|
||||||
buttonLabel: "Columbus",
|
buttonLabel: "Columbus",
|
||||||
buttonLabelSubCopy: "19.5 mi",
|
buttonLabelSubCopy: "19.5 mi",
|
||||||
value: "003342",
|
value: "003342",
|
||||||
|
additionalButtonData: wrapper.vm.additionalButtonData,
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue