class_docstr: Class containing unit tests for nltk.tgrep.
class_docstr_tok: ["Class","containing","unit","tests","for","nltk.tgrep","."]
docstr: Test a simple use of tgrep for finding nodes matching a given
  pattern.
docstr_tok: ["Test","a","simple","use","of","tgrep","for","finding","nodes","matching","a","given","pattern","."]
code: def test_node_simple(self):
      """
      Test a simple use of tgrep for finding nodes matching a given
      pattern.
      """
      tree = ParentedTree.fromstring(
          "(S (NP (DT the) (JJ big) (NN dog)) "
          "(VP bit) (NP (DT a) (NN cat)))"
      )
      self.assertEqual(
          list(tgrep.tgrep_positions("NN", [tree])), [[(0, 2), (2, 1)]]
      )
      self.assertEqual(
          list(tgrep.tgrep_nodes("NN", [tree])),
          [[tree[0, 2], tree[2, 1]]],
      )
      self.assertEqual(
          list(tgrep.tgrep_positions("NN|JJ", [tree])),
          [[(0, 1), (0, 2), (2, 1)]],
      )
  
imports: import unittest
  from nltk import tgrep
  from nltk.tree import ParentedTree
label_desc: Use image node_id 8 for calling the TestSequenceFunctions obj's underlying member method code with example usage: obj.test_node_simple() without return types