Reverting test_main to previous version