finalising midas module and tests.