code: def test_kwonly_marker(self):
      @kw_only_dataclasses.dataclass
      class A:
          x: float
          _: kw_only_dataclasses.KW_ONLY
          a: int = 5
          b: int = kw_only_dataclasses.field(default=2)
          c: int = kw_only_dataclasses.field(default=2, kw_only=True)
  
      @kw_only_dataclasses.dataclass
      class B(A):
          z: str
  
      a_params = inspect.signature(A.__init__).parameters
      b_params = inspect.signature(B.__init__).parameters
      self.assertEqual(list(a_params), ["self", "x", "a", "b", "c"])
      self.assertEqual(
          list(b_params), ["self", "x", "z", "a", "b", "c"]
      )
  
file_path: flax/tests/linen/kw_only_dataclasses_test.py
imports: import dataclasses
  import inspect
  from absl.testing import absltest
  from flax.linen import kw_only_dataclasses
label_desc: Use image node_id 4 for calling the KwOnlyDataclassesTest obj's underlying member method code with example usage: obj.test_kwonly_marker() without return types