Files
peptide-news-plugin/tests/unit/CliCommandsTest.php
opencode 7d2f795f99 feat: v2.6.0 3-step AI pipeline, VPS worker, REST worker routes
- 3-step OpenRouter pipeline: Gatekeeper scoring/classification, PubMed+Google URL extraction, Markdown summary generation
- REST worker routes /wp-json/peptide-news/v1/worker/* with X-Peptide-News-Token auth
- Standalone Coolify worker (tools/vps-worker) with Dockerfile + docker-compose
- CLI commands, content extractor, pubmed extractor, google url resolver
- 89 PHPUnit tests passing
2026-08-03 19:20:47 +08:00

25 lines
642 B
PHP

<?php
/**
* Unit tests for Peptide_News_CLI commands.
*
* @since 2.6.0
*/
use PHPUnit\Framework\TestCase;
class CliCommandsTest extends TestCase {
public function test_cli_class_exists_and_extends_command(): void {
$this->assertTrue( class_exists( 'Peptide_News_CLI' ) );
$cli = new Peptide_News_CLI();
$this->assertInstanceOf( 'WP_CLI_Command', $cli );
}
public function test_cli_methods_exist(): void {
$cli = new Peptide_News_CLI();
$this->assertTrue( method_exists( $cli, 'fetch' ) );
$this->assertTrue( method_exists( $cli, 'process_llm' ) );
$this->assertTrue( method_exists( $cli, 'backfill_sources' ) );
}
}