mirror of
https://github.com/TeaOSLab/EdgeCommon.git
synced 2025-11-03 04:10:25 +08:00
优化测试用例
This commit is contained in:
@@ -76,6 +76,18 @@ func TestURLPattern_Match(t *testing.T) {
|
||||
url: "/hidden/index.html",
|
||||
result: false, // because don't have https://HOST in url
|
||||
},
|
||||
{
|
||||
patternType: "wildcard",
|
||||
pattern: "*.jpg",
|
||||
url: "https://example.com/index.jpg",
|
||||
result: true,
|
||||
},
|
||||
{
|
||||
patternType: "wildcard",
|
||||
pattern: "*.jpg",
|
||||
url: "https://example.com/index.js",
|
||||
result: false,
|
||||
},
|
||||
{
|
||||
patternType: "regexp",
|
||||
pattern: ".*",
|
||||
|
||||
Reference in New Issue
Block a user