The tests should use scripts to remove all the duplication.
I'm rewriting all of the tests as part of bug 117898, so this bug is for tests that won't exist when I'm done. And I'll make sure the new tests are scripted as much as possible.