about summary refs log tree commit diff stats
path: root/tests_integration
diff options
context:
space:
mode:
authorAndrew Dolgov <fox@fakecake.org>2026-06-26 18:08:29 +0300
committerAndrew Dolgov <fox@fakecake.org>2026-06-26 18:08:29 +0300
commitd2b99dbd2aa1664a6095c0237372e5265dcbf761 (patch)
tree2ee961f7e90a98b6732a2fcead4a799fbdb5c58b /tests_integration
parent9b3a3d168098f3af024e8d0b98616ed620842668 (diff)
downloadthe-epube-d2b99dbd2aa1664a6095c0237372e5265dcbf761.tar.gz
the-epube-d2b99dbd2aa1664a6095c0237372e5265dcbf761.tar.xz
fix tests for new define format
Diffstat (limited to 'tests_integration')
-rw-r--r--tests_integration/DefineHandlerTest.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests_integration/DefineHandlerTest.php b/tests_integration/DefineHandlerTest.php
index 6dcce49..c695f6b 100644
--- a/tests_integration/DefineHandlerTest.php
+++ b/tests_integration/DefineHandlerTest.php
@@ -41,7 +41,7 @@ final class DefineHandlerTest extends ApiTestCase
 		$this->assertArrayHasKey('result', $body);
 		// Either disabled message or definitions
 		$isDisabled = isset($body['result'][0]) && $body['result'][0] === 'Dictionary lookups are disabled.';
-		$isDefined = isset($body['result'][0]) && str_contains($body['result'][0], '<strong>');
+		$isDefined = isset($body['result'][0]) && str_contains($body['result'][0], 'cat:');
 		$this->assertTrue($isDisabled || $isDefined, 'Expected either disabled message or definitions');
 	}
 
@@ -65,8 +65,8 @@ final class DefineHandlerTest extends ApiTestCase
 		$this->assertEquals(200, $status);
 		$this->assertArrayHasKey('result', $body);
 		$this->assertNotEmpty($body['result']);
-		// First result should be the word with <strong> tags
-		$this->assertEquals('<strong>cat</strong>', $body['result'][0]);
+		// First result should be the word with :
+		$this->assertEquals('cat:', $body['result'][0]);
 		// Followed by definition(s)
 		$this->assertGreaterThan(1, count($body['result']));
 	}
@@ -91,7 +91,7 @@ final class DefineHandlerTest extends ApiTestCase
 		$this->assertArrayHasKey('result', $body);
 		$this->assertNotEmpty($body['result']);
 		// Should match "cat" definition
-		$this->assertEquals('<strong>cats</strong>', $body['result'][0]);
+		$this->assertEquals('cats:', $body['result'][0]);
 	}
 
 	public function test_define_returns_no_results_for_unknown_word(): void