Last active
July 3, 2020 14:26
-
-
Save marcoemrich/a73ca66af567a58e765a98996fc1d1bc to your computer and use it in GitHub Desktop.
JS-Testing: Enzyme shallow rendering example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe('Board', () => { | |
it('should have the right number of cells', () => { | |
const wrapper = shallow(<Board game={TicTacToe.startWithSize(4, 4)} />); | |
expect(wrapper.find(Cell).length).toEqual(16); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment