Skip to content

Commit

Permalink
fix test cases issue (#968)
Browse files Browse the repository at this point in the history
Co-authored-by: Harsh Vardhan <harsh.vardhan@segment.com>
  • Loading branch information
hvardhan-unth and Harsh Vardhan authored Jul 2, 2024
1 parent 748a0fd commit 35aefe3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/core/src/__tests__/analytics.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ describe('SegmentClient', () => {
describe('#reset', () => {
it('resets all userInfo except anonymousId', async () => {
client = new SegmentClient(clientArgs);
const setUserInfo = jest.spyOn(client.userInfo, 'set');
const setUserInfo = jest.spyOn(store.userInfo, 'set');
await client.reset(false);

expect(setUserInfo).toHaveBeenCalledWith({
Expand All @@ -140,7 +140,7 @@ describe('SegmentClient', () => {

it('resets user data, identity, traits', async () => {
client = new SegmentClient(clientArgs);
const setUserInfo = jest.spyOn(client.userInfo, 'set');
const setUserInfo = jest.spyOn(store.userInfo, 'set');
await client.reset();

expect(setUserInfo).toHaveBeenCalledWith({
Expand Down
2 changes: 1 addition & 1 deletion packages/sovran/src/store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ export const createStore = <T extends object>(
}
}
} catch {
console.warn('Promise not handled correctly');
console.log('Promise not handled correctly');
} finally {
action?.finally?.(state);
}
Expand Down

0 comments on commit 35aefe3

Please sign in to comment.