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

Increase unit test coverage #173

Open
preslavmihaylov opened this issue Oct 22, 2021 · 0 comments
Open

Increase unit test coverage #173

preslavmihaylov opened this issue Oct 22, 2021 · 0 comments
Labels
good first issue Good for newcomers

Comments

@preslavmihaylov
Copy link
Owner

In order to submit this project for some of the curated go projects, we'll need to ensure a decent code coverage report. Currently, we don't have one since our integration tests are setup in a way that they test the application as a blackbox, which prevents us from having code coverage.

I'll welcome any PR which adds a new unit test & increases the code coverage.

@preslavmihaylov preslavmihaylov added the good first issue Good for newcomers label Oct 22, 2021
eisandbar added a commit to eisandbar/todocheck that referenced this issue Jul 30, 2022
Added unit tests for the 3 functions in matchers.go
eisandbar added a commit to eisandbar/todocheck that referenced this issue Jul 31, 2022
Changed checker to accept interface of type Fetcher for easier mocking. Added tests for all the possible errors that could happen in Check
eisandbar added a commit to eisandbar/todocheck that referenced this issue Aug 1, 2022
Refactored fetcher to use fetcher.sendRequest instead of hclient.Do for easier testing. Added tests for fetch function for all possible errors
eisandbar added a commit to eisandbar/todocheck that referenced this issue Aug 25, 2022
Added unit tests for the 3 functions in matchers.go
eisandbar added a commit to eisandbar/todocheck that referenced this issue Aug 25, 2022
Changed checker to accept interface of type Fetcher for easier mocking. Added tests for all the possible errors that could happen in Check
eisandbar added a commit to eisandbar/todocheck that referenced this issue Aug 25, 2022
Refactored fetcher to use fetcher.sendRequest instead of hclient.Do for easier testing. Added tests for fetch function for all possible errors
preslavmihaylov added a commit that referenced this issue Sep 11, 2022
* Tests for matchers package #173

Added unit tests for the 3 functions in matchers.go

* Tests for checker package #173

Changed checker to accept interface of type Fetcher for easier mocking. Added tests for all the possible errors that could happen in Check

* Tests for fetcher package #173

Refactored fetcher to use fetcher.sendRequest instead of hclient.Do for easier testing. Added tests for fetch function for all possible errors

* style(test): Simplified return statements in fetcher and checker tests

Fixed lint issues associated with return statements

Co-authored-by: Preslav Mihaylov <pmihaylov95@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant