From bd6f923f43bc53c48f5c782de8de101b9d9a2974 Mon Sep 17 00:00:00 2001 From: kngwyu Date: Fri, 9 Nov 2018 13:11:47 +0900 Subject: [PATCH] Fix #240 --- examples/rustapi_module/tests/test_datetime.py | 3 +-- src/typeob.rs | 5 ----- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/examples/rustapi_module/tests/test_datetime.py b/examples/rustapi_module/tests/test_datetime.py index eb91c8b8135..b34b47d448c 100644 --- a/examples/rustapi_module/tests/test_datetime.py +++ b/examples/rustapi_module/tests/test_datetime.py @@ -272,10 +272,9 @@ def test_tz_class(): assert dt.utcoffset() == pdt.timedelta(hours=1) assert dt.dst() is None -@pytest.mark.skip(reason='to debug with the latest master') def test_tz_class_introspection(): tzi = rdt.TzClass() assert tzi.__class__ == rdt.TzClass - assert repr(tzi) == "TzClass()" + assert repr(tzi).startswith('(type_object); - if type_object.tp_base - != unsafe { &ffi::PyBaseObject_Type as *const ffi::PyTypeObject as *mut ffi::PyTypeObject } - { - type_object.tp_flags |= ffi::Py_TPFLAGS_HEAPTYPE - } // register type object unsafe {