implemented the tests for MtlOpt.