vdenotaris / spring-boot-security-saml-sample

SBS3 — A sample SAML 2.0 Service Provider built on Spring Boot.
https://sbs3.vdenotaris.com
Apache License 2.0
562 stars 351 forks source link

Unit tests to increase code coverage from 7.5% to 99% #19

Closed airleks closed 8 years ago

airleks commented 8 years ago

This pull request is focused on package org.jooq.tools.json. Code coverage is measured using JaCoCo. This pull request increases code coverage of the whole project by 91.5%.

Spring configuration files were excluded from coverage estimation.

Please note that all test files were moved to src/test directory to run with maven properly. Their previous location in unit tests sample commit was invalid (that was my fault, sorry).

Metric Before After
Coverage % 7.5% 99%
Lines Covered 15 196
Total Lines 199 199

Please let me know if you have any questions.

Alexey Syrtsev DevFactory - Code Quality Team

vdenotaris commented 8 years ago

Hi,

Can you just give a look to the test units? According to Travis, all the checks have failed: https://travis-ci.org/vdenotaris/spring-boot-security-saml-sample/builds/104915184

Regards, V.

airleks commented 8 years ago

Hi.

As Travis reported the reason is 'The log length has exceeded the limit of 4 MB (this usually means that the test suite is raising the same exception over and over). The job has been terminated'

The logs are huge because of logger DEBUG-mode enabled. Hence all the test runs produce amounts of debug logs. I can change log4j.properties for unit tests to use INFO level. Please let me know if it is ok for you.

Regards, Alexey Syrtsev DevFactory - Code Quality Team

vdenotaris commented 8 years ago

Now seems to be everything fine. I will merge the pull request asap. Thank you so much for you contribution, I will add your name in the README file ;)

Best regards, V.

airleks commented 8 years ago

Oh, thank you :)

Kind Regards Alexey