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
| test('should update the value when onChange is called', () => { | |
| nameField.onChange({ target: { value: 'nitin' } }); | |
| expect(nameField.value).toBe('nitin'); | |
| }); |
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
| test('should update the value when onChange is called', () => { | |
| act(() => { | |
| nameField.onChange({ target: { value: 'nitin' } }); | |
| }); | |
| expect(nameField.value).toBe('nitin'); | |
| }); |
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
| breakingRecords :: [Int] -> [Int] | |
| updateMinMax [maxRec,minRec,max, min] score = | |
| [newMaxRec,newMinRec,newMax,newMin] | |
| where | |
| newMax = if score > max then score else max | |
| newMin = if score < min then score else min | |
| newMaxRec = if newMax > max then (maxRec + 1) else maxRec | |
| newMinRec = if newMin < min then (minRec + 1) else minRec |
OlderNewer