code: def test_invalid_spec(self):
      # Invalid format:
      self.assertRaises(
          "validation[:250%:2]",
          "Unrecognized split format: 'validation[:250%:2]'",
      )
      # Unexisting split:
      self.assertRaises("imaginary", "Unknown split 'imaginary'")
      # Invalid boundaries abs:
      self.assertRaises(
          "validation[:31]", "incompatible with 30 examples"
      )
      # Invalid boundaries %:
      self.assertRaises(
          "validation[:250%]",
          "percent slice boundaries should be in [-100, 100]",
      )
      self.assertRaises(
          "validation[-101%:]",
          "percent slice boundaries should be in [-100, 100]",
      )
      # pct1_dropremainder with < 100 examples
      with self.assertRaisesWithPredicateMatch(
          ValueError, "with less than 100 elements is forbidden"
      ):
          ri = splits.ReadInstruction(
              "validation",
              to=99,
              unit="%",
              rounding="pct1_dropremainder",
          )
          ri.to_absolute(self.splits)
  
imports: from tensorflow_datasets import testing
  from tensorflow_datasets.core import naming
  from tensorflow_datasets.core import proto
  from tensorflow_datasets.core import splits
  from tensorflow_datasets.core.utils import shard_utils
  import tensorflow_datasets.public_api
label_desc: Use image node_id 9 for calling the ReadInstructionTest obj's underlying member method code with example usage: obj.test_invalid_spec() without return types