fix
This commit is contained in:
parent
a833488c22
commit
7b5e15d1ca
|
@ -51,9 +51,8 @@ function testParseUrl(fn: (acct: string) => acct.Acct) {
|
||||||
expect(() => fn('https://example.com/@')).toThrowError();
|
expect(() => fn('https://example.com/@')).toThrowError();
|
||||||
});
|
});
|
||||||
|
|
||||||
it('parses url ended with /', () => {
|
it('throws ended with /', () => {
|
||||||
const res = fn('https://example.com/@alice/');
|
expect(() => fn('https://example.com/@alice/')).toThrowError();
|
||||||
expect(res).toEqual({ username: 'alice', host: 'example.com' });
|
|
||||||
});
|
});
|
||||||
|
|
||||||
it('throws url have @username path but ended with sub directory', () => {
|
it('throws url have @username path but ended with sub directory', () => {
|
||||||
|
|
Loading…
Reference in New Issue