aboutsummaryrefslogtreecommitdiff
path: root/test/shared/utils
diff options
context:
space:
mode:
authorShin'ya UEOKA <ueokande@i-beam.org>2019-10-05 06:39:20 +0000
committerShin'ya UEOKA <ueokande@i-beam.org>2019-10-06 12:58:59 +0000
commitb86b4680b6c2a3f0cceefaaf7c2e35417ec555df (patch)
tree79296d48f79ebba2496de5e8e09a4c8fc9e1ad41 /test/shared/utils
parent574692551a27ea56660bf2061daeaa0d34beaff4 (diff)
Make Blacklist class
Diffstat (limited to 'test/shared/utils')
-rw-r--r--test/shared/utils/re.test.ts19
1 files changed, 0 insertions, 19 deletions
diff --git a/test/shared/utils/re.test.ts b/test/shared/utils/re.test.ts
deleted file mode 100644
index d12ceb7..0000000
--- a/test/shared/utils/re.test.ts
+++ /dev/null
@@ -1,19 +0,0 @@
-import * as re from 'shared/utils/re';
-
-describe("re util", () => {
- it('matches by pattern', () => {
- let regex = re.fromWildcard('*.example.com/*');
- expect('foo.example.com/bar').to.match(regex);
- expect('foo.example.com').not.to.match(regex);
- expect('example.com/bar').not.to.match(regex);
-
- regex = re.fromWildcard('example.com/*')
- expect('example.com/foo').to.match(regex);
- expect('example.com/').to.match(regex);
-
- regex = re.fromWildcard('example.com/*bar')
- expect('example.com/foobar').to.match(regex);
- expect('example.com/bar').to.match(regex);
- expect('example.com/foobarfoo').not.to.match(regex);
- })
-});