MDL-41062 gradebook: corrections to grade_item upgrade script, more tests