docstr: Tests generator invalidation with fake heuristic.
docstr_tok: ["Tests","generator","invalidation","with","fake","heuristic","."]
code: def test_nl_generator_invalidation_check(self):
      """Tests generator invalidation with fake heuristic."""
      # Expected to give 6 matches.
      input_batches = [
          pa.array([["MATCH", "MATCH", "MATCH"], ["MATCH"]]),
          pa.array([["MATCH", "MATCH"]]),
          # Incorrect type invalidates accumulator.
          pa.array([[42]]),
      ]
      # No domain_info is generated as the incorrect type of 42 value invalidated
      # the stats.
      generator = nlsg.NLDomainInferringStatsGenerator(
          _FakeHeuristic(), values_threshold=1
      )
      self.assertCombinerOutputEqual(
          input_batches,
          generator,
          statistics_pb2.FeatureNameStatistics(),
      )
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from absl.testing import absltest
  import pyarrow
  from tensorflow_data_validation.statistics.generators import natural_language_domain_inferring_stats_generator
  from tensorflow_data_validation.utils import test_util
  from typing import Text
  from tensorflow_metadata.proto.v0 import statistics_pb2
label_desc: Use image node_id 10 for calling the NaturalLanguageStatsGeneratorTest obj's underlying member method code with example usage: obj.test_nl_generator_invalidation_check() without return types