Use the MAKE envirobnment variable, and extract a bit of commonality.
expectError() actually does this right (catches AlreadyClosedException too) so use the right tool for the job.