|
1202 | 1202 | { |
1203 | 1203 | "pattern": [{ "protocol": "http", "port": "80 " }], |
1204 | 1204 | "inputs": [{ "protocol": "http", "port": "80" }], |
| 1205 | + "exactly_empty_components": ["port"], |
| 1206 | + "expected_match": { |
| 1207 | + "protocol": { "input": "http", "groups": {} } |
| 1208 | + } |
| 1209 | + }, |
| 1210 | + { |
| 1211 | + "pattern": [{ "protocol": "http", "port": "100000" }], |
| 1212 | + "inputs": [{ "protocol": "http", "port": "100000" }], |
1205 | 1213 | "expected_obj": "error" |
1206 | 1214 | }, |
1207 | 1215 | { |
|
2424 | 2432 | }, |
2425 | 2433 | { |
2426 | 2434 | "pattern": [{ "hostname": "bad#hostname" }], |
2427 | | - "expected_obj": "error" |
| 2435 | + "exactly_empty_components": ["port"], |
| 2436 | + "expected_match": { |
| 2437 | + "hostname": { "input": "bad", "groups": {} } |
| 2438 | + } |
2428 | 2439 | }, |
2429 | 2440 | { |
2430 | 2441 | "pattern": [{ "hostname": "bad%hostname" }], |
2431 | | - "expected_obj": "error" |
| 2442 | + "exactly_empty_components": ["port"], |
| 2443 | + "expected_match": { |
| 2444 | + "hostname": { "input": "bad%hostname", "groups": {} } |
| 2445 | + } |
2432 | 2446 | }, |
2433 | 2447 | { |
2434 | 2448 | "pattern": [{ "hostname": "bad/hostname" }], |
2435 | | - "expected_obj": "error" |
| 2449 | + "exactly_empty_components": ["port"], |
| 2450 | + "expected_match": { |
| 2451 | + "hostname": { "input": "bad", "groups": {} } |
| 2452 | + } |
2436 | 2453 | }, |
2437 | 2454 | { |
2438 | 2455 | "pattern": [{ "hostname": "bad\\:hostname" }], |
|
2476 | 2493 | }, |
2477 | 2494 | { |
2478 | 2495 | "pattern": [{ "hostname": "bad\nhostname" }], |
2479 | | - "expected_obj": "error" |
| 2496 | + "exactly_empty_components": ["port"], |
| 2497 | + "expected_match": { |
| 2498 | + "hostname": { "input": "badhostname", "groups": {} } |
| 2499 | + } |
2480 | 2500 | }, |
2481 | 2501 | { |
2482 | 2502 | "pattern": [{ "hostname": "bad\rhostname" }], |
2483 | | - "expected_obj": "error" |
| 2503 | + "exactly_empty_components": ["port"], |
| 2504 | + "expected_match": { |
| 2505 | + "hostname": { "input": "badhostname", "groups": {} } |
| 2506 | + } |
2484 | 2507 | }, |
2485 | 2508 | { |
2486 | 2509 | "pattern": [{ "hostname": "bad\thostname" }], |
2487 | | - "expected_obj": "error" |
| 2510 | + "exactly_empty_components": ["port"], |
| 2511 | + "expected_match": { |
| 2512 | + "hostname": { "input": "badhostname", "groups": {} } |
| 2513 | + } |
2488 | 2514 | }, |
2489 | 2515 | { |
2490 | 2516 | "pattern": [{}], |
|
0 commit comments