Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

enzyme debounce test

jest.useFakeTimers();
test('TEST Rizqi to be Benny',() => { 
  wrapper.find('#button4').simulate('click')
  jest.advanceTimersByTime(50000);
  expect(wrapper.state('nama2')).toBe('benny')
});
 
PREVIOUS NEXT
Tagged: #enzyme #debounce #test
ADD COMMENT
Topic
Name
8+8 =