diff --git a/tests/BlueskyThreadsTest.php b/tests/BlueskyThreadsTest.php index 5ab2e6e..df77d77 100644 --- a/tests/BlueskyThreadsTest.php +++ b/tests/BlueskyThreadsTest.php @@ -145,13 +145,13 @@ class BlueskyThreadsTest extends TestCase { $this->assertStringContainsString('hockeyviz.com', $html); } - /** Both reply authors must appear in the rendered HTML. */ + /** Reply post authors are not rendered; only quoted post authors are. */ public function testReplyAuthorsAreRendered(): void { $data = json_decode(file_get_contents(__DIR__ . '/fixtures/thread_3mhtk7awhrp26.json'), true); $html = $this->call('renderThread', $data['thread'], true); - $this->assertStringContainsString('example.bsky.social', $html, 'First reply author must be present'); - $this->assertStringContainsString('hockeyfan.bsky.social', $html, 'Second reply author must be present'); + $this->assertStringNotContainsString('example.bsky.social', $html, 'Reply author must not appear in thread posts'); + $this->assertStringNotContainsString('hockeyfan.bsky.social', $html, 'Reply author must not appear in thread posts'); } /** The quoted/embedded post inside the root is rendered via renderQuotedRecord. */ @@ -164,12 +164,13 @@ class BlueskyThreadsTest extends TestCase { 'Quoted post text must be rendered as an embed'); } - /** Every post must include a "View on Bluesky" link pointing to the right URL. */ + /** Quoted posts include a "View on Bluesky" link; thread posts do not. */ public function testViewOnBskyLinksArePresent(): void { $data = json_decode(file_get_contents(__DIR__ . '/fixtures/thread_3mhtk7awhrp26.json'), true); $html = $this->call('renderThread', $data['thread'], true); - $this->assertStringContainsString('3mhtk7awhrp26', $html, 'Root post rkey must appear in a Bluesky link'); + $this->assertStringNotContainsString('3mhtk7awhrp26', $html, 'Thread post rkey must not appear as a permalink'); + $this->assertStringContainsString('3mhtjo3rtkn26', $html, 'Quoted post rkey must appear in its View on Bluesky link'); $this->assertStringContainsString('View on Bluesky', $html); }