Skip to content

Conversation

@HazAT
Copy link
Member

@HazAT HazAT commented Dec 15, 2017

No description provided.

@HazAT HazAT self-assigned this Dec 15, 2017
@HazAT HazAT requested a review from kamilogorek as a code owner December 15, 2017 10:57
const spy2 = jest.spyOn(sentry.getAdapter(), 'install');
await sentry.install();
await sentry.install();
expect(spy1).toHaveBeenCalledTimes(2);
Copy link
Contributor

Choose a reason for hiding this comment

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

This assertion looks redundant, because you trigger those calls yourself 2 lines above

const spy = jest.spyOn(sentry, 'setRelease');
const spy2 = jest.spyOn(sentry.getAdapter(), 'setRelease');
await sentry.setRelease('#oops');
expect(spy).toBeCalled();
Copy link
Contributor

Choose a reason for hiding this comment

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

Same here


public setUserContext(user?: IUser) {
public getContext() {
// TODO: check for cyclic objects
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks for the review, so about this function. I wasn't able to import the existing implementation and I want to have a fancy typescript and also thinking about if it would be possible to prevent circular refs upon setting it instead of reading.

@HazAT HazAT merged commit 851129a into master Dec 20, 2017
@HazAT HazAT deleted the feature/core-additions branch December 20, 2017 12:06
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.

3 participants