MCPcopy
hub / github.com/gofiber/fiber / Test_Domain_Security_EmptyPattern

Function Test_Domain_Security_EmptyPattern

domain_test.go:1554–1564  ·  view source on GitHub ↗

Test_Domain_Security_EmptyPattern tests that empty domain patterns are rejected

(t *testing.T)

Source from the content-addressed store, hash-verified

1552
1553// Test_Domain_Security_EmptyPattern tests that empty domain patterns are rejected
1554func Test_Domain_Security_EmptyPattern(t *testing.T) {
1555 t.Parallel()
1556
1557 require.Panics(t, func() {
1558 parseDomainPattern("")
1559 })
1560
1561 require.Panics(t, func() {
1562 parseDomainPattern(" ")
1563 })
1564}
1565
1566// Test_Domain_Security_EmptyLabel tests that domain patterns with empty labels are rejected
1567func Test_Domain_Security_EmptyLabel(t *testing.T) {

Callers

nothing calls this directly

Calls 1

parseDomainPatternFunction · 0.85

Tested by

no test coverage detected