feat: article editor core
This commit is contained in:
1 parent
d493a181e1
commit
a4734b2c91
55 files changed
+4186
-496
No files matched your search
@@ -8,7 +8,10 @@ beforeEach(() => {
|
||||
resetAuthShellNavigation()
|
||||
})
|
||||
|
||||
function mountShell(props: Record<string, unknown>, slots: Record<string, unknown> = {}) {
|
||||
function mountShell(
|
||||
props: Record<string, unknown>,
|
||||
slots: Record<string, unknown> = {},
|
||||
) {
|
||||
return mount(AuthShell, {
|
||||
props,
|
||||
slots,
|
||||
@@ -63,13 +66,17 @@ describe('AuthShell renders its notice and footer slots', () => {
|
||||
|
||||
const notice = wrapper.find('span')
|
||||
expect(notice.text()).toBe('Your session expired.')
|
||||
expect(wrapper.findAll('[data-slot="root"][data-orientation]').length).toBe(1)
|
||||
expect(
|
||||
wrapper.findAll('[data-slot="root"][data-orientation]').length,
|
||||
).toBe(1)
|
||||
|
||||
const card = wrapper.find('[data-testid="auth-card"]')
|
||||
expect(card.element.contains(notice.element)).toBe(true)
|
||||
|
||||
const html = wrapper.html()
|
||||
expect(html.indexOf('<h1')).toBeLessThan(html.indexOf('Your session expired.'))
|
||||
expect(html.indexOf('<h1')).toBeLessThan(
|
||||
html.indexOf('Your session expired.'),
|
||||
)
|
||||
|
||||
const footerLink = wrapper.find('a[href="/register/reset/request"]')
|
||||
expect(footerLink.exists()).toBe(true)
|
||||
|
||||
Reference in new issue
Block a user