tests: avoid failure when running with no tty