class_docstr: Test class for JSONParser
class_docstr_tok: ["Test","class","for","JSONParser"]
docstr: JSONParser - Single nested JSON
docstr_tok: ["JSONParser","-","Single","nested","JSON"]
code: def test_single_nested_json(self):
      """JSONParser - Single nested JSON"""
      options = {
          "schema": {"middlekey1": "string", "middlekey2": []},
          "configuration": {"json_path": "topkey"},
      }
  
      expected_record = {"middlekey1": "1", "middlekey2": []}
  
      data = {
          "topkey": {
              "middlekey1": "1",
              "middlekey2": [],
          }
      }
  
      record_data = json.dumps(data)
  
      # get parsed data
      parser = JSONParser(options)
      assert_equal(parser.parse(record_data), True)
  
      expected_result = [expected_record]
      assert_equal(parser.parsed_records, expected_result)
  
imports: import json
  from mock import patch
  from nose.tools import assert_equal
  from streamalert.classifier.parsers import JSONParser
label_desc: Use image node_id 11 for calling the TestJSONParser obj's underlying member method code with example usage: obj.test_single_nested_json() without return types