Bug 742951 - Fix tests (and code) to work with MySQL