Fix for #4489 -- apply was using the rest terminus
Basing pervasive low-level behaviour changes on the application name isn't a
good idea, but if we're going to do it we need to remember to update the test
when we rename the application.
I am not certain that this change is globally correct; there may be other
related problems that will not be fixed (and may in fact be exacerbated) by
this patch.