Improved fix for FM-347, where autoRewind false would prevent subsequent playback. The new fix is to base the autoRewind-on-play decision on an internal "mediaAtEnd" property rather than on the duration equalling the currentTime. The problem with the latter is that some media (e.g. HTTP streamed DVR content, as seen in FM-681) will dispatch the "complete" event without the currentTime equalling the duration, and in fact the currentTime may never end up equalling the duration. Added unit test to catch the original bug.