Skip to content

Commit 7bef889

Browse files
committed
Fix index check order
1 parent 12e2168 commit 7bef889

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tests/e2e/Adapter/Scopes/IndexTests.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,12 @@ public function testIndexValidation(): void
268268
);
269269

270270
$this->assertFalse($validator->isValid($newIndex));
271-
$this->assertEquals('There is already a fulltext index in the collection', $validator->getDescription());
271+
272+
if (!$database->getAdapter()->getSupportForMultipleFulltextIndexes()) {
273+
$this->assertEquals('There is already a fulltext index in the collection', $validator->getDescription());
274+
} elseif ($database->getAdapter()->getSupportForAttributes()) {
275+
$this->assertEquals('Attribute "integer" cannot be part of a fulltext index, must be of type string', $validator->getDescription());
276+
}
272277

273278
try {
274279
$database->createCollection($collection->getId(), $attributes, $indexes);

0 commit comments

Comments
 (0)