Tests happened in head. This should be moved to a JS-only file.