Add functional test for 'clean' subcommand