import { mount } from '@vue/test-utils'
import { describe, it, expect, vi } from 'vitest'
import InviteManager from '../InviteManager.vue'

// Mock clipboard
vi.stubGlobal('navigator', {
    clipboard: {
        writeText: vi.fn().mockResolvedValue(undefined),
    },
})

describe('InviteManager.vue', () => {
    it('shows generate button when no invite', () => {
        const wrapper = mount(InviteManager, {
            props: { groupId: 1 },
        })
        expect(wrapper.text()).toContain('Generate Invite Code')
    })
}) 