code: def test_entities_replace(self):
      self.assertRaises(
          AssertionError, cnner_sample.entities_replace, [], ["啥也不是"]
      )
      self.assertRaises(
          AssertionError, cnner_sample.entities_replace, ["啥也不是"], []
      )
      self.assertRaises(
          AssertionError, cnner_sample.entities_replace, ["啥也不是"], ""
      )
  
      replaced = cnner_sample.entities_replace(
          [{"start": 2, "end": 3, "entity": "浦东", "tag": "GPE"}],
          ["浦东新区"],
      )
      self.assertEqual(
          {
              "x": [
                  "上",
                  "海",
                  "浦",
                  "东",
                  "新",
                  "区",
                  "开",
                  "发",
                  "与",
                  "法",
                  "制",
                  "建",
                  "设",
                  "同",
                  "步",
              ],
              "y": [
                  "B-GPE",
                  "E-GPE",
                  "B-GPE",
                  "M-GPE",
                  "M-GPE",
                  "E-GPE",
                  "O",
                  "O",
                  "O",
                  "O",
                  "O",
                  "O",
                  "O",
                  "O",
                  "O",
              ],
              "sample_id": None,
          },
          replaced.dump(),
      )
  
imports: import unittest
  from textflint.input.component.sample.nercn_sample import *
label_desc: Use image node_id 4 for calling the TestNERCnSample obj's underlying member method code with example usage: obj.test_entities_replace() without return types