Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

679 B
Raw Blame
import { afterEach, describe, expect, it, vi } from 'vitest';
import { dismissBootShell } from './boot-shell';

afterEach(() => {
  document.body.innerHTML = '';
  vi.useRealTimers();
});

describe('dismissBootShell', () => {
  it('fades the shell, then removes it', () => {
    vi.useFakeTimers();
    document.body.innerHTML = '<div id="boot-shell"></div>';

    dismissBootShell();

    expect(document.getElementById('boot-shell')?.dataset.leaving).toBe('');
    vi.advanceTimersByTime(400);
    expect(document.getElementById('boot-shell')).toBeNull();
  });

  it('does nothing once the shell is gone', () => {
    expect(() => dismissBootShell()).not.toThrow();
  });
});