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

User-friendly errors #12

Merged
merged 3 commits into from Sep 17, 2015
Merged

User-friendly errors #12

merged 3 commits into from Sep 17, 2015

Conversation

terfilip
Copy link
Contributor

Simply will throw error in case an object from NCBI has undefined properties that are required by bionode. The message will mention this could be an NCBI problem, and show the URL of the request.

Test data was out of date and making travis CI fail for the current blonde-ncbi. I updated test/data.json to have current ncbi data and make tests pass. Some fetched with script here + manual changes such as replacing 'content' with '_'.

@terfilip
Copy link
Contributor Author

@bmpvieira Do you want me to add do a test for the error handling? The error occurs when transform gets an empty object. I guess the testing could be done by mocking the ncbi url using nock or something, and send back an empty/invalid object, to trigger the error.

Signed-off-by: Filip Ter <filip.ter@gmail.com>
Signed-off-by: Filip Ter <filip.ter@gmail.com>
Signed-off-by: Filip Ter <filip.ter@gmail.com>
bmpvieira added a commit that referenced this pull request Sep 17, 2015
@bmpvieira bmpvieira merged commit edb75c1 into bionode:master Sep 17, 2015
@terfilip terfilip deleted the errors branch September 30, 2015 20:04
@terfilip terfilip restored the errors branch September 30, 2015 20:04
@terfilip terfilip deleted the errors branch October 27, 2015 23:34
@bmpvieira bmpvieira self-requested a review April 6, 2017 10:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging this pull request may close these issues.

None yet

2 participants