Revamped unit_tests.py

Change-Id: I115fabd7d17469ab86d1a236ee021145a2c0a03a