You take the written test to show that you know how to read road signage. After you pass that, you can then bring that you a motocycle training facility/classes near you and start learning. From what I understand, it's in some sort of closed in area as taking you out on the road is too dangerous. You can then do the actual riding test which you can think of as an obstacle course of sorts to get your actual riding M license. Also, be prepared to pick up some bikes from the ground. Your ability to pick up various bikes from a on-its-side-on-the-ground position to an upright position determine what class of motorcycles you're allowed to buy/ride (more of a strength test than anything really).
^ that's what I know about it, although I'm sure things have changed in the last, uh, decade.