Added tests for POST requests. Refactored test hierarchy.

Still missing some complex test for GET and POST validation.