'Agreed. It is ugly, but it works.'

def test_copy_relations_on_page_extension(self):

    self.assertCheck(True, warnings=0, errors=0)
    copy_rel = MyPageExtension.copy_relations
    del MyPageExtension.copy_relations
    self.assertCheck(True, warnings=1, errors=0)
    MyPageExtension.copy_relations = copy_rel
