test setting command to null throws exception