Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: bump RN to 0.62 #273

Merged
merged 2 commits into from
Apr 20, 2020
Merged

chore: bump RN to 0.62 #273

merged 2 commits into from
Apr 20, 2020

Conversation

thymikee
Copy link
Member

@thymikee thymikee commented Apr 3, 2020

Summary

Blocked by facebook/react-native#28520

Test plan

CI passes

@@ -57,7 +57,9 @@ describe('fireEvent', () => {
});

test('should throw an Error when event handler was not found', () => {
const { getByTestId } = render(<WithoutEventComponent />);
const { getByTestId } = render(
<WithoutEventComponent onPress={() => 'this is not passed to children'} />
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Based on #28 I've added this instead of the should not bubble event to root element test that started to fail

Comment on lines -82 to -92
test('should not bubble event to root element', () => {
const onPressMock = jest.fn();
const { getByTestId } = render(
<TouchableOpacity onPress={onPressMock}>
<Text testID="test">Content</Text>
</TouchableOpacity>
);

expect(() => fireEvent.press(getByTestId('test'))).toThrow();
expect(onPressMock).not.toHaveBeenCalled();
});
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test seems fishy and not testing what it's supposed to. Not really sure why it didn't fail earlier, since the test testID is there, we can press it, and closest onPress is bound, so it should be called.

@thymikee thymikee requested review from Esemesek and cross19xx April 17, 2020 07:11
@thymikee thymikee merged commit d8fd154 into master Apr 20, 2020
@thymikee thymikee deleted the chore/bump-rn branch April 20, 2020 09:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants