Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR TYPESCRIPT

jest not toBe

// .not - Test the opposite
const bestLaCroixFlavor = 'strawberry';
test('the best flavor is not coconut', () => {
  expect(bestLaCroixFlavor).not.toBe('coconut');
});
Source by jestjs.io #
 
PREVIOUS NEXT
Tagged: #jest #toBe
ADD COMMENT
Topic
Name
2+4 =