code: def test_posonly_methods(self):
      class Example:
          def f(self, a, b, /):
              return a, b
  
      self.assertEqual(Example().f(1, 2), (1, 2))
      self.assertEqual(Example.f(Example(), 1, 2), (1, 2))
      self.assertRaises(TypeError, Example.f, 1, 2)
      expected = r"f\(\) got some positional-only arguments passed as keyword arguments: 'b'"
      with self.assertRaisesRegex(TypeError, expected):
          Example().f(1, b=2)
  
imports: import dis
  import pickle
  import unittest
  from test.support import check_syntax_error
label_desc: Use image node_id 18 for calling the PositionalOnlyTestCase obj's underlying member method code with example usage: obj.test_posonly_methods() and returns: a,  b