Skip to content

Commit

Permalink
refactor: clean up some listed Problems
Browse files Browse the repository at this point in the history
  • Loading branch information
mikechu-optimizely committed Dec 6, 2023
1 parent 377496e commit 78d704d
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/Experiment.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import { OptimizelyVariation } from './Variation';

describe('<OptimizelyExperiment>', () => {
const variationKey = 'matchingVariation';
// eslint-disable-next-line @typescript-eslint/no-explicit-any
let resolver: any;
let optimizelyMock: ReactSDKClient;
let isReady: boolean;
Expand All @@ -40,12 +41,12 @@ describe('<OptimizelyExperiment>', () => {
});

optimizelyMock = ({
onReady: jest.fn().mockImplementation(config => onReadyPromise),
activate: jest.fn().mockImplementation(experimentKey => variationKey),
onUserUpdate: jest.fn().mockImplementation(handler => () => { }),
onReady: jest.fn().mockImplementation(() => onReadyPromise),
activate: jest.fn().mockImplementation(() => variationKey),
onUserUpdate: jest.fn().mockImplementation(() => () => { }),
notificationCenter: {
addNotificationListener: jest.fn().mockImplementation((type, handler) => { }),
removeNotificationListener: jest.fn().mockImplementation(id => { }),
addNotificationListener: jest.fn().mockImplementation(() => { }),
removeNotificationListener: jest.fn().mockImplementation(() => { }),
},
user: {
id: 'testuser',
Expand Down

0 comments on commit 78d704d

Please sign in to comment.