fixed cs, added validation and added tests
ordered use statements a-z
Merge pull request #28 from kbond/apc-fix

fixed cs, added validation and added tests for APC checks