class_docstr: Test class for JSONParser
class_docstr_tok: ["Test","class","for","JSONParser"]
docstr: JSONParser - Regex key with envelope
docstr_tok: ["JSONParser","-","Regex","key","with","envelope"]
code: def test_json_regex_key_with_envelope(self):
      """JSONParser - Regex key with envelope"""
      options = self._json_regex_key_options()
  
      # Valid record data
      record_data = json.dumps(
          {
              "time": "14:01",
              "date": "Jan 01, 2017",
              "host": "host1.test.domain.tld",
              "message": "<10> auditd[1300] info: "
              '{"nested_key_01": "foo",'
              '"nested_key_02": "bar"}',
          }
      )
  
      # get parsed data
      parser = JSONParser(options)
      assert_equal(parser.parse(record_data), True)
  
      expected_result = [
          {
              "nested_key_01": "foo",
              "nested_key_02": "bar",
              "streamalert:envelope_keys": {
                  "host": "host1.test.domain.tld",
                  "date": "Jan 01, 2017",
                  "time": "14:01",
              },
          }
      ]
      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 13 for calling the TestJSONParser obj's underlying member method code with example usage: obj.test_json_regex_key_with_envelope() without return types