I agree with WWW, as long as the exercise is done in a controlled situation, ie., over a suitable aerodrome, with altitude to spare(and keys still in the ignition), it should be done. I got the experience of an air restart as part of my initial instructor rating. This was done in a C150 Aerobat.
Like hand-swinging a prop to start the engine, it's something I'm glad I've done once under supervision, but I'm also in no rush to do it again.