Use a pipe to test stderr forwarding

* Assertion was accidentally removed when testing #read as an
  alternative.