Skip to content

Commit

Permalink
chore: additional test-cases to verify expected failures
Browse files Browse the repository at this point in the history
  • Loading branch information
Sai Sankeerth committed Nov 6, 2024
1 parent 25d3eb9 commit de001e4
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions test/data/validation/destinations/webhook.json
Original file line number Diff line number Diff line change
Expand Up @@ -998,5 +998,38 @@
"err": [
"webhookUrl must match pattern \"(^\\{\\{.*\\|\\|(.*)\\}\\}$)|(^env[.].+)|^(https?://)(?![a-zA-Z0-9-]*\\.ngrok\\.io)(?!localhost|.*\\.localhost)([a-zA-Z0-9-]{1,63}\\.)+[a-zA-Z]{2,}(:\\d+)?(/.*)?$\""
]
},
{
"testTitle": ".localhost with port",
"config": {
"webhookUrl": "https://test.localhost:443",
"webhookMethod": "GET"
},
"result": false,
"err": [
"webhookUrl must match pattern \"(^\\{\\{.*\\|\\|(.*)\\}\\}$)|(^env[.].+)|^(https?://)(?![a-zA-Z0-9-]*\\.ngrok\\.io)(?!localhost|.*\\.localhost)([a-zA-Z0-9-]{1,63}\\.)+[a-zA-Z]{2,}(:\\d+)?(/.*)?$\""
]
},
{
"testTitle": "valid dns with port with invalid port",
"config": {
"webhookUrl": "https://example.com:abc",
"webhookMethod": "GET"
},
"result": false,
"err": [
"webhookUrl must match pattern \"(^\\{\\{.*\\|\\|(.*)\\}\\}$)|(^env[.].+)|^(https?://)(?![a-zA-Z0-9-]*\\.ngrok\\.io)(?!localhost|.*\\.localhost)([a-zA-Z0-9-]{1,63}\\.)+[a-zA-Z]{2,}(:\\d+)?(/.*)?$\""
]
},
{
"testTitle": "https://localhost with port",
"config": {
"webhookUrl": "http://localhost:9090",
"webhookMethod": "GET"
},
"result": false,
"err": [
"webhookUrl must match pattern \"(^\\{\\{.*\\|\\|(.*)\\}\\}$)|(^env[.].+)|^(https?://)(?![a-zA-Z0-9-]*\\.ngrok\\.io)(?!localhost|.*\\.localhost)([a-zA-Z0-9-]{1,63}\\.)+[a-zA-Z]{2,}(:\\d+)?(/.*)?$\""
]
}
]

0 comments on commit de001e4

Please sign in to comment.