Fix up some out-of-date tests and a single bug

With these changes, all the tests pass again.