PSLmodels / Business-Taxation

USA Corporate and Pass-Through Business Tax Model
11 stars 10 forks source link

Add more fast-executing tests to increase test suite's code coverage #65

Closed martinholmer closed 5 years ago

martinholmer commented 5 years ago

This pull request adds some tests that increase code coverage. As in the other PSL tax model repositories, code coverage is based only on tests that are not marked @pytest.mark.requires_pufcsv. Before this pull request there were 29 such tests, which take about 55 seconds to execute when using the pytest -n4 -m "not requires_pufcsv" command on my computer.

Before adding any new tests (as of commit 7b8d5a4, which configures the coverage tool and marks two tests as requires_pufcsv), the 29-test coverage rate is 58% and the detailed coverage report looks like this:

Screen Shot 2019-03-14 at 10 33 30 AM

After the final commit in this pull request, there are more tests marked @pytest.mark.requires_pufcsv, which take about 68 seconds to execute when using the pytest -n4 -m "not requires_pufcsv" command on my computer. The additional tests raise the test coverage rate from 58% to 75%.

There will be more tests added in subsequent pull requests.

martinholmer commented 5 years ago

@codykallen, pull request #65 is ready for review.

codykallen commented 5 years ago

@martinholmer, these tests (and minor nonsubstantive modifications to some of the other files) look good to me. If there are no more changes forthcoming to this PR, I'll be happy to merge it in.

martinholmer commented 5 years ago

@codykallen said in PR #65:

these tests (and minor nonsubstantive modifications to some of the other files) look good to me. If there are no more changes forthcoming to this PR, I'll be happy to merge it in.

OK. Go ahead with the merge. I will propose more tests later, but this is some improvement in test coverage.