Add method to add a command for testing.