Remove effect-free tests. Part 5 of (BUGZ-4206)
Several I/O statements were expressed as calls with tests for the calls' results, but the results of the tests were never used. There did not seem to be good reason to introduce any further testing or add any error propagation (cf the case directly below), so the redundant tests were removed.