Skip to main content
Glama
AscendServerTest.php1.72 kB
<?php declare(strict_types=1); use GoldenPathDigital\LaravelAscend\Server\AscendServer; beforeEach(function (): void { $knowledgeBasePath = dirname(__DIR__, 2) . '/resources/knowledge-base'; $this->server = AscendServer::createDefault($knowledgeBasePath); }); it('returns knowledge base info through the server facade', function (): void { $info = $this->server->getKnowledgeBaseInfo(); expect($info) ->toHaveKey('knowledge_base_version') ->toHaveKey('pattern_count'); }); it('searches knowledge base content via server', function (): void { $results = $this->server->searchKnowledgeBase('SwiftMailer'); expect($results)->toBeArray()->not->toBeEmpty(); expect($results[0])->toHaveKey('type'); }); it('lists identifiers for future MCP tool integrations', function (): void { expect($this->server->listBreakingChangeSlugs())->toContain('laravel-7'); expect($this->server->listPatternIdentifiers())->toContain('swiftmailer-to-symfony-mailer'); expect($this->server->listUpgradePathIdentifiers())->toContain('6-to-7'); }); it('executes documentation tools via the registry', function (): void { $tools = $this->server->listToolNames(); expect($tools)->toContain('search_upgrade_docs'); expect($tools)->toContain('analyze_current_version'); $response = $this->server->callTool('search_upgrade_docs', [ 'query' => 'SwiftMailer', 'limit' => 2, ]); expect($response) ->toHaveKey('ok', true) ->toHaveKey('data') ->and($response['data']['results'])->not->toBeEmpty(); expect($this->server->describeResources())->toBeArray(); expect($this->server->describePrompts())->toBeArray(); });

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/aarongrtech/laravel-ascend'

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