code: def test_slotnames(self):
      self.assertEqual(copyreg._slotnames(WithoutSlots), [])
      self.assertEqual(copyreg._slotnames(WithWeakref), [])
      expected = ["_WithPrivate__spam"]
      self.assertEqual(copyreg._slotnames(WithPrivate), expected)
      expected = ["_WithLeadingUnderscoreAndPrivate__spam"]
      self.assertEqual(
          copyreg._slotnames(_WithLeadingUnderscoreAndPrivate), expected
      )
      self.assertEqual(copyreg._slotnames(___), ["__spam"])
      self.assertEqual(copyreg._slotnames(WithSingleString), ["spam"])
      expected = ["eggs", "spam"]
      expected.sort()
      result = copyreg._slotnames(WithInherited)
      result.sort()
      self.assertEqual(result, expected)
  
imports: import copyreg
  import unittest
  from test.pickletester import ExtensionSaver
label_desc: Use image node_id 6 for calling the CopyRegTestCase obj's underlying member method code with example usage: obj.test_slotnames() without return types