ported test_rmsm to mac