Skip to content

Commit 86921d0

Browse files
fix: fixed failing tests
1 parent a47ea68 commit 86921d0

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/preferences-unsubscribe/index.test.jsx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,7 @@ describe('Notification Preferences One Click Unsubscribe', () => {
2424
let component;
2525
let store;
2626
const userToken = '1234';
27-
const updatePatch = 'abc123';
28-
const url = getUnsubscribeUrl(userToken, updatePatch);
27+
const url = getUnsubscribeUrl(userToken);
2928

3029
beforeAll(async () => {
3130
await initializeTestStore();
@@ -39,7 +38,7 @@ describe('Notification Preferences One Click Unsubscribe', () => {
3938
component = (
4039
<AppProvider store={store} wrapWithRouter={false}>
4140
<UserMessagesProvider>
42-
<MemoryRouter initialEntries={[`${`/preferences-unsubscribe/${userToken}/${updatePatch}/`}`]}>
41+
<MemoryRouter initialEntries={[`${`/preferences-unsubscribe/${userToken}/`}`]}>
4342
<Routes>
4443
<Route path={ROUTES.PREFERENCES_UNSUBSCRIBE} element={<PreferencesUnsubscribe />} />
4544
</Routes>
@@ -69,7 +68,6 @@ describe('Notification Preferences One Click Unsubscribe', () => {
6968
expect(screen.getByTestId('heading-text')).toHaveTextContent('Error unsubscribing from preference');
7069
expect(sendTrackEvent).toHaveBeenCalledWith('edx.ui.lms.notifications.preferences.unsubscribe', {
7170
userToken,
72-
updatePatch,
7371
});
7472
});
7573
});

0 commit comments

Comments
 (0)