Add optional functions to view and tests