Earl, when you say you can hear the motor running, do you mean like it's trying to turn or is it just humming. The one sure way to check to see if the cable has become detached is to open it manually from the trunk. I am sure the set up is the same for all Benzes. In the trunk, on the left side you should see an access hole to the sunroof motor. There is a bolt there that you can use your tire iron to turn, or you can use a 17mm socket and turn the bolt counter-clockwise. This is how I open and closed my sunroof, until I repaired some wiring. If the cable is broken, then you'll be cranking but the roof panle will just sit there.
Just curious, does your state inspect the operation of sunroofs as part of the inspection? I only ask becuase it seems you are concerned about the sunroof not working because of an up coming insp.
1994 MB E320 Coupe (199,500 mi)
1992 MB 190E 2.6 (173,000 mi)
1983 Porsche 911SC (148,000 mi)
2004 Volvo V70 2.5T (198,000 mi)
President of CT/Westchester Section