1. Removed all DEBUG/ASSERT statements
2. Improved test case