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

Unit Testing #26

Open
projectgoav opened this issue Dec 14, 2015 · 4 comments
Open

Unit Testing #26

projectgoav opened this issue Dec 14, 2015 · 4 comments
Milestone

Comments

@projectgoav
Copy link
Owner

No description provided.

@filipkristo
Copy link
Contributor

@projectgoav Maybe we can create new deezer account for unit test purpose? I thing that would be easy way to cover all methods with tests...

@projectgoav
Copy link
Owner Author

I did some work a long time ago on mocking out the API to return fake data but never continued. Working working on some UI as a sample use of the library so might continue this once that's complete.

Performing tests against the real API is difficult as without logging in the calls are rate limited and the test would probably hit this value very quickly. There's no easy way to automate authentication on the public API Deezer provide

@PoLaKoSz
Copy link
Contributor

PoLaKoSz commented Jul 2, 2019

Hi!

I would like to help so I started to work on this issue. You can find my progress here (I will merge a few commits together after I finished):

https://github.com/PoLaKoSz/E.Deezer/tree/develop/clean-code

Can You give me some feedback about this solution?
Thank You!

📓Notes:

  • Found 2 bug while I wrote a few tests (this are the failing Unit tests)
  • Coverage changed (41.04% -> 48.05%)
  • Implemented a new approach which hopefully make the development and the testing more easy (mocking the server response)

@projectgoav
Copy link
Owner Author

projectgoav commented Jul 2, 2019

Thanks for looking into this. When you feel ready, submit it as a PR and I'll give it a review! :)

Edit: I find it easier to review as a change-set rather than browse through the source files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants