Skip to content

Commit 6a8583e

Browse files
committed
chore: write tests
add extra test case for uppercase on `Bit.ly`
1 parent a3ada12 commit 6a8583e

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

test/shared/util/validation.test.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@ describe('Test whiteliste check', () => {
99
})
1010

1111
describe('Test blacklist check', () => {
12+
test('example GooGle.com url is not blacklisted', () => {
13+
const url = 'https://www.GooGle.com'
14+
expect(validation.isBlacklisted(url)).toBe(false)
15+
})
16+
1217
test('localstack url is not blacklisted', () => {
1318
const url = 'http://localhost:4566'
1419
expect(validation.isBlacklisted(url)).toBe(false)
@@ -18,6 +23,11 @@ describe('Test blacklist check', () => {
1823
const url = 'https://bit.ly/abc'
1924
expect(validation.isBlacklisted(url)).toBe(true)
2025
})
26+
27+
test('example Bit.Ly url is also blacklisted', () => {
28+
const url = 'https://Bit.Ly/abc'
29+
expect(validation.isBlacklisted(url)).toBe(true)
30+
})
2131
})
2232

2333
describe('Test https check', () => {

0 commit comments

Comments
 (0)