Issue #6: read subcommands from standard input
Fixed unit-tests.