Test combined priority and trailers.
(host, port)
| 201 | |
| 202 | |
| 203 | def test_combined(host, port): |
| 204 | """Test combined priority and trailers.""" |
| 205 | print("\n=== Testing Combined Features ===") |
| 206 | |
| 207 | try: |
| 208 | sock, h2_conn = create_h2_connection(host, port) |
| 209 | |
| 210 | response = h2_request(sock, h2_conn, 1, 'GET', '/combined', f'{host}:{port}') |
| 211 | print(f"Status: {response['status']}") |
| 212 | |
| 213 | data = json.loads(response['body'].decode()) |
| 214 | print(f"Response: {json.dumps(data, indent=2)}") |
| 215 | |
| 216 | if response['trailers']: |
| 217 | print(f"Trailers: {response['trailers']}") |
| 218 | |
| 219 | sock.close() |
| 220 | return response['status'] == 200 |
| 221 | except Exception as e: |
| 222 | print(f"ERROR: {e}") |
| 223 | return False |
| 224 | |
| 225 | |
| 226 | def test_multiple_streams(host, port): |
no test coverage detected