Added setting the rundir field in the top test for iterated tests. Added MT_MEGATEST variable to make it easier to write tests and find the megatest executable