Added testing

This commit is contained in:
2024-04-22 11:56:36 -04:00
parent 99344fda7d
commit 96d0232d78
13 changed files with 287 additions and 4 deletions

19
tests/TransactionTest.php Normal file
View File

@ -0,0 +1,19 @@
<?php
use PHPUnit\Framework\TestCase;
use ProVM\Database\Transaction;
class TransactionTest extends TestCase
{
public function testTransaction()
{
$connection = $this->createMock(ProVM\Concept\Database\Connection::class);
$transaction = new Transaction($connection);
$transaction->begin();
$this->assertTrue(true);
$transaction->commit();
$this->assertTrue(true);
$transaction->begin();
$transaction->rollback();
$this->assertTrue(true);
}
}