import { readFileSync } from 'node:fs'
import path from 'node:path'

import { describe, expect, it } from 'vitest'

describe('brain graph embedding', () => {
  it('renders the reusable graph projection component directly instead of an iframe shell', () => {
    const brainPage = readFileSync(path.resolve(__dirname, './index.vue'), 'utf-8')

    expect(brainPage).toContain('GraphProjection')
    expect(brainPage).not.toContain('<iframe')
    expect(brainPage).not.toContain('src="/graph"')
  })
})
