move order of dialog boxes.
move trial deletion function to trial class.
improve error reporting of deletion functions.
return descriptive error messages.
add a trial to the fixture, then delete it for testing.
fix patch.
move delete functions to Trial object; rewire controller; implement more comprehensive unit test for Trial object.