Update testdox for remaining unit tests

This commit is contained in:
2024-09-22 20:18:17 -04:00
parent 294b608ac8
commit 91bf3128c5
12 changed files with 69 additions and 48 deletions

View File

@@ -24,7 +24,7 @@ class PatchTest extends TestCase
Configuration::overrideMode(null);
parent::tearDown();
}
#[TestDox('By ID succeeds for PostgreSQL')]
#[TestDox('byId() succeeds for PostgreSQL')]
public function testByIdSucceedsForPostgreSQL(): void
{
Configuration::overrideMode(Mode::PgSQL);
@@ -32,7 +32,7 @@ class PatchTest extends TestCase
Patch::byId('doc_table'), 'Patch UPDATE statement is not correct');
}
#[TestDox('By ID succeeds for SQLite')]
#[TestDox('byId() succeeds for SQLite')]
public function testByIdSucceedsForSQLite(): void
{
Configuration::overrideMode(Mode::SQLite);
@@ -40,14 +40,14 @@ class PatchTest extends TestCase
Patch::byId('my_table'), 'Patch UPDATE statement is not correct');
}
#[TestDox('By ID fails when mode not set')]
#[TestDox('byId() fails when mode not set')]
public function testByIdFailsWhenModeNotSet(): void
{
$this->expectException(DocumentException::class);
Patch::byId('oof');
}
#[TestDox('By fields succeeds for PostgreSQL')]
#[TestDox('byFields() succeeds for PostgreSQL')]
public function testByFieldsSucceedsForPostgreSQL(): void
{
Configuration::overrideMode(Mode::PgSQL);
@@ -55,7 +55,7 @@ class PatchTest extends TestCase
Patch::byFields('that', [Field::less('something', 17, ':some')]), 'Patch UPDATE statement is not correct');
}
#[TestDox('By fields succeeds for SQLite')]
#[TestDox('byFields() succeeds for SQLite')]
public function testByFieldsSucceedsForSQLite(): void
{
Configuration::overrideMode(Mode::SQLite);
@@ -65,13 +65,14 @@ class PatchTest extends TestCase
'Patch UPDATE statement is not correct');
}
#[TestDox('byFields() fails when mode not set')]
public function testByFieldsFailsWhenModeNotSet(): void
{
$this->expectException(DocumentException::class);
Patch::byFields('oops', []);
}
#[TestDox('By contains succeeds for PostgreSQL')]
#[TestDox('byContains() succeeds for PostgreSQL')]
public function testByContainsSucceedsForPostgreSQL(): void
{
Configuration::overrideMode(Mode::PgSQL);
@@ -79,14 +80,14 @@ class PatchTest extends TestCase
'Patch UPDATE statement is not correct');
}
#[TestDox('By contains fails for non PostgreSQL')]
#[TestDox('byContains() fails for non PostgreSQL')]
public function testByContainsFailsForNonPostgreSQL(): void
{
$this->expectException(DocumentException::class);
Patch::byContains('');
}
#[TestDox('By JSON Path succeeds for PostgreSQL')]
#[TestDox('byJsonPath() succeeds for PostgreSQL')]
public function testByJsonPathSucceedsForPostgreSQL(): void
{
Configuration::overrideMode(Mode::PgSQL);
@@ -94,7 +95,7 @@ class PatchTest extends TestCase
Patch::byJsonPath('that'), 'Patch UPDATE statement is not correct');
}
#[TestDox('By JSON Path fails for non PostgreSQL')]
#[TestDox('byJsonPath() fails for non PostgreSQL')]
public function testByJsonPathFailsForNonPostgreSQL(): void
{
$this->expectException(DocumentException::class);