OpenBuildings / postmark

Postmark transport for Swift Mailer
https://github.com/OpenBuildings/postmark
BSD 3-Clause "New" or "Revised" License
16 stars 8 forks source link

Improve tests structure and test coverage #10

Closed hkdobrev closed 9 years ago

hkdobrev commented 9 years ago

The test coverage reported was 97%, but it was quite closer to 0 than 100 if you include @covers annotations.

I've introduced unit tests to cover all of the functionality (except for the invalid JSON response) and now the test coverage is realistic. Scrutinizer CI shows 98.65% 98.37% https://scrutinizer-ci.com/g/OpenBuildings/postmark/inspections/e3a3e0a8-c41e-482e-8353-b68931686c2c/code-structure/test-coverage

I've also improved the tests structure with better autoloading of helper classes.

hkdobrev commented 9 years ago

I have rebased on latest master and removed the test for not receiving a response. It was not a reliable test in all environments. The test coverage is now around 98%.

/cc @dkyosev

dkyosev commented 9 years ago

LGTM