Skip to content

Commit f638eac

Browse files
committed
fix footer test
1 parent 981dbc0 commit f638eac

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

src/v2/components/footer/Footer.test.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ describe('SolidUIFooterElement', () => {
1616
const shadow = footer.shadowRoot
1717
expect(shadow).not.toBeNull()
1818
expect(shadow?.textContent).toContain('Public View')
19-
expect(shadow?.textContent).toContain('You are viewing this profile as a guest,')
19+
expect(shadow?.textContent).toContain('You are viewing this profile as a guest.')
2020
})
2121

2222
it('renders a logged in view when the user is authenticated', async () => {
@@ -30,7 +30,10 @@ describe('SolidUIFooterElement', () => {
3030
const shadow = footer.shadowRoot
3131
expect(shadow).not.toBeNull()
3232
expect(shadow?.textContent).toContain('Logged in View')
33-
expect(shadow?.textContent).toContain('You are logged in as https://alice.example/profile/card#me user.')
33+
expect(shadow?.textContent).toContain('You are logged in as')
34+
const link = shadow?.querySelector('a')
35+
expect(link?.getAttribute('href')).toBe('https://alice.example/profile/card#me')
36+
expect(link?.textContent).toBe('https://alice.example/profile/card#me')
3437

3538
currentUserSpy.mockRestore()
3639
})

0 commit comments

Comments
 (0)