title: How do I test if a stream has ended?
body: <p>I have a stream that may or may not have already ended. If it has ended, I don't want to sit there forever waiting for the <code>end</code> event. How do I check?</p>