Skip to content

Commit

Permalink
Begin to write a regression test
Browse files Browse the repository at this point in the history
  • Loading branch information
nlisgo committed Feb 28, 2025
1 parent 95bd3e7 commit 0fa5816
Showing 1 changed file with 21 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<?php

namespace tests\eLife\Search\Indexer\ModelIndexer;

use eLife\Search\Api\Elasticsearch\MappedElasticsearchClient;
use eLife\Search\Indexer\ModelIndexer\ElasticsearchBackedReviewedPreprintLifecycle;
use PHPUnit\Framework\Attributes\Test;
use PHPUnit\Framework\TestCase;

final class ElasticsearchBackedReviewedPreprintLifecycleTest extends TestCase
{
#[Test]
public function givenAReviewedPreprintIdWhenNoSupportedArticleTypeWithThatIdIsFoundThenIsNotSuperseded()
{
$this->markTestSkipped();
// @phpstan-ignore deadCode.unreachable
$client = $this->createStub(MappedElasticsearchClient::class);
$result = (new ElasticsearchBackedReviewedPreprintLifecycle($client))->isSuperseded('');
$this->assertFalse($result);
}
}

0 comments on commit 0fa5816

Please sign in to comment.