Add tests: localhost is a "sneaky link"

This commit is contained in:
Evan Hahn 2020-09-09 15:15:03 -05:00 committed by Scott Nonnenberg
parent 7a02cc815d
commit a04f9a0e51

View file

@ -430,6 +430,8 @@ describe('Link previews', () => {
it("returns true if the domain doesn't contain a .", () => {
assert.isTrue(isLinkSneaky('https://example'));
assert.isTrue(isLinkSneaky('https://localhost'));
assert.isTrue(isLinkSneaky('https://localhost:3000'));
});
it('returns true if the domain has any empty labels', () => {