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

Start increasing testing and code coverage #175

Merged
merged 2 commits into from
Nov 20, 2020
Merged

Start increasing testing and code coverage #175

merged 2 commits into from
Nov 20, 2020

Conversation

bassosimone
Copy link
Contributor

This diff starts increasing the code coverage in some parts of the codebase. The general approach is that of adding some extra abstraction that allows us to mock what's happening in all internal/cli packages. Until this refactoring for testability process is complete, we will have a bit of duplication. Yet, doing everything in a single step requires us to write a too large diff and seems not the right approach here. This work is part of ooni/probe#948.

There are two reasons why I'm starting to refactor the code base now. The first is that the code is now settled for quite some time and it's more or less clear what are our needs, so the time seems ripe to add tests to ensure we WAI. The second is that I am planning on further integrating probe-cli and probe-engine. To this end, we need good testing in place.

As a final remark, one of the most important objectives of testing this codebase is ensuring that we're not breaking the contract with probe-desktop as far as the --batch command line option is concerned.

@bassosimone bassosimone merged commit 7a43975 into master Nov 20, 2020
@bassosimone bassosimone deleted the testing branch November 20, 2020 11:59
ainghazal pushed a commit to ainghazal/probe-cli that referenced this pull request Mar 8, 2022
Start increasing testing and code coverage
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant