updated tests condition

This commit is contained in:
ArnabChatterjee20k
2025-11-21 19:08:35 +05:30
parent 6eb17b847f
commit fdf5ca0067
2 changed files with 12 additions and 4 deletions
@@ -493,9 +493,17 @@ trait DatabasesBase
$this->assertEquals(400, $attribute['headers']['status-code']);
$maxLength = $this->isMongoDB() ? 1024 : 768;
$this->assertStringContainsString('Index length is longer than the maximum: '.$maxLength, $attribute['body']['message']);
$message = $attribute['body']['message'];
if ($this->MongoDB()) {
$this->assertStringContainsString('Index length is longer than the maximum: 1024', $message);
} else {
// length depends on the shared table
$this->assertTrue(
str_contains($message, 'Index length is longer than the maximum: 767') ||
str_contains($message, 'Index length is longer than the maximum: 768'),
"Message does not contain expected max length"
);
}
}
public function testUpdateAttributeEnum(): void
@@ -8663,7 +8663,7 @@ trait DatabasesBase
'$id' => 'row1',
'name' => 'Test Row 1',
'pointAttr' => [6.0, 6.0],
'lineAttr' => [[1.0, 1.0], [2.0, 2.0]],
'lineAttr' => [[1.0, 1.0], [1.1,1.1] , [2.0, 2.0]],
'polyAttr' => [[[0.0, 0.0], [10.0, 0.0], [10.0, 10.0], [0.0, 10.0], [0.0, 0.0]]]
],
[