Unit test failures in test_atoms.py
===================================================================================== FAILURES =====================================================================================
____________________________________________________________________________ TestGdkAtom.test_out_array ____________________________________________________________________________
self = <test_atoms.TestGdkAtom testMethod=test_out_array>
@unittest.skipIf(sys.platform == "darwin", "fails on OSX")
def test_out_array(self):
a_selection = Gdk.Atom.intern('my_clipboard', False)
clipboard = Gtk.Clipboard.get(a_selection)
# empty
(res, targets) = clipboard.wait_for_targets()
self.assertEqual(res, False)
self.assertEqual(targets, [])
# text
clipboard.set_text('hello', 5)
(res, targets) = clipboard.wait_for_targets()
> self.assertEqual(res, True)
E AssertionError: False != True
____________________________________________________________________________ TestGdkAtom.test_out_glist ____________________________________________________________________________
self = <test_atoms.TestGdkAtom testMethod=test_out_glist>
@unittest.skipIf(sys.platform == "darwin" or os.name == "nt",
"fails on OSX/Windows")
@unittest.skipIf(not Gdk or Gdk._version == "4.0", "not in gdk4")
def test_out_glist(self):
display = Gdk.Display.get_default()
with capture_glib_deprecation_warnings():
dm = display.get_device_manager()
device = dm.get_client_pointer()
axes = device.list_axes()
> axes_names = [atom.name() for atom in axes]
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.0 = <list_iterator object at 0x7fde4f4122e8>
> axes_names = [atom.name() for atom in axes]
E AttributeError: 'NoneType' object has no attribute 'name'
In test_out_glist the gdk_device_list_axes returns a list with two GDK_NONE (null pointer) as elements.
Both failures could be related to the fact that I am running tests under Wayland.