Index: test/abp2blocklist.js |
=================================================================== |
--- a/test/abp2blocklist.js |
+++ b/test/abp2blocklist.js |
@@ -271,14 +271,20 @@ |
test.done(); |
}, |
testUnicode: function(test) |
{ |
testRules(test, ["$domain=๐.cat"], ["*xn--zn8h.cat"], |
rules => rules[0]["trigger"]["if-domain"]); |
- testRules(test, ["๐$domain=๐.cat"], []); |
+ testRules(test, ["||๐"], "^https?://([^/]+\\.)?xn--zn8h", |
+ rules => rules[0]["trigger"]["url-filter"]); |
+ testRules(test, ["๐$domain=๐.cat"], "^https?://.*%F0%9F%90%88", |
+ rules => rules[0]["trigger"]["url-filter"]); |
+ testRules(test, ["๐%F0%9F%90%88$domain=๐.cat"], |
+ "^https?://.*%F0%9F%90%88%F0%9F%90%88", |
+ rules => rules[0]["trigger"]["url-filter"]); |
testRules(test, ["###๐"], []); |
test.done(); |
} |
}; |