Update url-helpers.test.ts
This commit is contained in:
@@ -146,7 +146,8 @@ describe('splitApexDomain', () => {
|
||||
})
|
||||
|
||||
describe('isTrustedUrl', () => {
|
||||
const cases = [
|
||||
type Case = [string, boolean]
|
||||
const cases: Case[] = [
|
||||
['#', true],
|
||||
['#profile', true],
|
||||
['/', true],
|
||||
@@ -171,7 +172,7 @@ describe('isTrustedUrl', () => {
|
||||
['https://docs.google.com', false],
|
||||
['https://google.com/#', false],
|
||||
['https://blueskywebxzendesk.com', false],
|
||||
] as [string, boolean][]
|
||||
]
|
||||
|
||||
it.each(cases)('given input uri %p, returns %p', (str, expected) => {
|
||||
const output = isTrustedUrl(str)
|
||||
|
||||
Reference in New Issue
Block a user