Make TestErrorDuringStartup more resilient against different setups

While the previous coding would always work in Travis, there's no reason
to fail "go test" on other setups.