Skip to main content
Glama
MUSE-CODE-SPACE

Vibe Coding Documentation MCP (MUSE)

publishDocument.test.js3.38 kB
import { publishDocument } from '../tools/publishDocument.js'; describe('publishDocument', () => { const sampleDocument = `# Test Document This is a test document for publishing. ## Features - Feature 1 - Feature 2 `; describe('Notion publishing', () => { it('should return result for Notion platform', async () => { const result = await publishDocument({ document: sampleDocument, title: 'Test Doc', platform: 'notion' }); expect(result.result).toBeDefined(); expect(result.result.platform).toBe('notion'); }); it('should handle missing Notion API key gracefully', async () => { const result = await publishDocument({ document: sampleDocument, title: 'Test Doc', platform: 'notion' }); expect(result.result).toBeDefined(); }); }); describe('GitHub Wiki publishing', () => { it('should return result for GitHub Wiki platform', async () => { const result = await publishDocument({ document: sampleDocument, title: 'Test Doc', platform: 'github-wiki' }); expect(result.result).toBeDefined(); expect(result.result.platform).toBe('github-wiki'); }); }); describe('Obsidian publishing', () => { it('should return result for Obsidian platform', async () => { const result = await publishDocument({ document: sampleDocument, title: 'Test Doc', platform: 'obsidian' }); expect(result.result).toBeDefined(); expect(result.result.platform).toBe('obsidian'); }); it('should work with vault path option', async () => { const result = await publishDocument({ document: sampleDocument, title: 'Test Doc', platform: 'obsidian', options: { vaultPath: '/path/to/vault' } }); expect(result.result).toBeDefined(); }); }); describe('output format', () => { it('should include platform in result', async () => { const result = await publishDocument({ document: sampleDocument, title: 'Test', platform: 'notion' }); expect(result.result.platform).toBe('notion'); }); it('should include success status', async () => { const result = await publishDocument({ document: sampleDocument, title: 'Test', platform: 'obsidian' }); expect(typeof result.result.success).toBe('boolean'); }); }); describe('error handling', () => { it('should handle unsupported platform', async () => { const result = await publishDocument({ document: sampleDocument, title: 'Test', platform: 'unknown-platform' }); expect(result.result.success).toBe(false); expect(result.result.error).toContain('Unsupported platform'); }); }); }); //# sourceMappingURL=publishDocument.test.js.map

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/MUSE-CODE-SPACE/vibe-coding-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server