From 4b856138923b0224b7666124419be2dd2c83942f Mon Sep 17 00:00:00 2001 From: Yutao Yuan Date: Mon, 28 Aug 2023 10:39:45 +0800 Subject: [PATCH] fix test failures --- src/sage/combinat/cluster_complex.py | 2 +- src/sage/structure/sage_object.pyx | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/sage/combinat/cluster_complex.py b/src/sage/combinat/cluster_complex.py index 3c85d8db7a4..e263d983887 100644 --- a/src/sage/combinat/cluster_complex.py +++ b/src/sage/combinat/cluster_complex.py @@ -267,7 +267,7 @@ def _repr_(self): sage: ClusterComplex(['A', 2])._repr_() "Cluster complex of type ['A', 2] with 5 vertices and 5 facets" """ - if k == 1: + if self._k == 1: name = 'Cluster complex' else: name = 'Multi-cluster complex' diff --git a/src/sage/structure/sage_object.pyx b/src/sage/structure/sage_object.pyx index af9c0008672..10000aef394 100644 --- a/src/sage/structure/sage_object.pyx +++ b/src/sage/structure/sage_object.pyx @@ -160,6 +160,9 @@ cdef class SageObject: sage: P.rename('A polynomial ring') sage: P.get_custom_name() 'A polynomial ring' + sage: P.reset_name() + sage: P.get_custom_name() is None + True """ try: return self._SageObject__custom_name