diff --git a/tests/packetbeat b/tests/packetbeat index 340162449bd6..b819fbf96757 160000 --- a/tests/packetbeat +++ b/tests/packetbeat @@ -1 +1 @@ -Subproject commit 340162449bd6cbf50124301fd96f2fd43c6e2bd3 +Subproject commit b819fbf967578cbd791374741fb13f3f769fa988 diff --git a/tests/templates/packetbeat.conf.j2 b/tests/templates/packetbeat.conf.j2 index 83d739faa36a..f3e3587617a8 100644 --- a/tests/templates/packetbeat.conf.j2 +++ b/tests/templates/packetbeat.conf.j2 @@ -82,7 +82,7 @@ idl_files = [ [http] {% if http_send_all_headers %}send_all_headers = true{% endif %} -{% if http_split_set_cookie %}split_set_cookie = true{% endif %} +{% if http_split_cookie %}split_cookie = true{% endif %} {% if http_send_headers -%} send_headers = [{%- for hdr in http_send_headers -%} "{{ hdr }}" diff --git a/tests/test_0006_wsgi.py b/tests/test_0006_wsgi.py index e5301d0534b6..e3ac9078477c 100644 --- a/tests/test_0006_wsgi.py +++ b/tests/test_0006_wsgi.py @@ -106,11 +106,11 @@ def test_send_headers_options(self): assert len(o["http"]["response"]["headers"]) == 1 assert "user-agent" in o["http"]["request"]["headers"] - def test_split_set_cookie(self): + def test_split_cookie(self): self.render_config_template( http_ports=[8888], http_send_all_headers=True, - http_split_set_cookie=True, + http_split_cookie=True, ) self.run_packetbeat(pcap="wsgi_loopback.pcap") @@ -120,5 +120,9 @@ def test_split_set_cookie(self): assert len(o["http"]["request"]["headers"]) == 9 assert len(o["http"]["response"]["headers"]) == 7 + + assert isinstance(o["http"]["request"]["headers"]["cookie"], dict) + assert len(o["http"]["request"]["headers"]["cookie"]) == 6 + assert isinstance(o["http"]["response"]["headers"]["set-cookie"], dict) assert len(o["http"]["response"]["headers"]["set-cookie"]) == 4