43 lines
1.3 KiB
JavaScript
43 lines
1.3 KiB
JavaScript
import { describe, it, expect, $ } from './runner.js';
|
|
|
|
describe('App Shell', () => {
|
|
it('header with logo', () => {
|
|
expect($('header')).toExist();
|
|
expect($('#logo') || $('header h1')).toExist();
|
|
});
|
|
|
|
it('board element with relative positioning', () => {
|
|
const board = $('#board');
|
|
expect(board).toExist();
|
|
expect(board.classList.contains('relative')).toBe(true);
|
|
});
|
|
|
|
it('footer buttons', () => {
|
|
for (const id of ['settings-btn', 'export-btn', 'import-btn', 'logout-btn', 'export-md-btn']) {
|
|
expect($(`#${id}`)).toExist();
|
|
}
|
|
});
|
|
|
|
it('header buttons', () => {
|
|
for (const id of ['search-btn', 'calendar-btn', 'gallery-btn', 'add-btn']) {
|
|
expect($(`#${id}`)).toExist();
|
|
}
|
|
});
|
|
|
|
it('toolbar controls', () => {
|
|
for (const id of ['bucket-bar', 'board-split-toggle', 'superview-toggle', 'hide-done', 'hide-termine', 'sort-toggle', 'sort-label']) {
|
|
expect($(`#${id}`)).toExist();
|
|
}
|
|
});
|
|
|
|
it('footer card count', () => {
|
|
const fc = $('#footer-count');
|
|
expect(fc).toExist();
|
|
expect(fc.textContent).toContain('card');
|
|
});
|
|
|
|
it('hidden file inputs', () => {
|
|
expect($('#import-file')).toExist();
|
|
});
|
|
});
|