Skip to content

Commit 3d329a4

Browse files
committed
revert test
1 parent 71d1aab commit 3d329a4

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

packages/react-paypal-js/src/v6/components/PayLaterOneTimePaymentButton.test.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ describe("PayLaterOneTimePaymentButton", () => {
4646

4747
it("should render a div when not hydrated", () => {
4848
mockUsePayPal.mockReturnValue({
49+
eligiblePaymentMethods: null,
4950
isHydrated: false,
5051
});
5152
const { container } = render(
@@ -162,6 +163,7 @@ describe("PayLaterOneTimePaymentButton", () => {
162163
describe("auto-population from eligibility context", () => {
163164
it("should auto-populate countryCode and productCode from eligibility context", () => {
164165
mockUsePayPal.mockReturnValue({
166+
isHydrated: true,
165167
eligiblePaymentMethods: {
166168
isEligible: jest.fn().mockReturnValue(true),
167169
getDetails: jest.fn().mockReturnValue({
@@ -170,7 +172,6 @@ describe("PayLaterOneTimePaymentButton", () => {
170172
canBeVaulted: false,
171173
}),
172174
},
173-
isHydrated: true,
174175
});
175176

176177
const { container } = render(
@@ -188,8 +189,8 @@ describe("PayLaterOneTimePaymentButton", () => {
188189

189190
it("should handle when eligibility was not fetched", () => {
190191
mockUsePayPal.mockReturnValue({
191-
eligiblePaymentMethods: null,
192192
isHydrated: true,
193+
eligiblePaymentMethods: null,
193194
});
194195

195196
const { container } = render(
@@ -207,11 +208,11 @@ describe("PayLaterOneTimePaymentButton", () => {
207208

208209
it("should handle when PayLater details are not available", () => {
209210
mockUsePayPal.mockReturnValue({
211+
isHydrated: true,
210212
eligiblePaymentMethods: {
211213
isEligible: jest.fn().mockReturnValue(false),
212214
getDetails: jest.fn().mockReturnValue(undefined),
213215
},
214-
isHydrated: true,
215216
});
216217

217218
const { container } = render(

0 commit comments

Comments
 (0)