Skip to content

Commit e8c0533

Browse files
committed
Add test data for #322
Signed-off-by: William Desportes <[email protected]>
1 parent 887750d commit e8c0533

8 files changed

Lines changed: 1827 additions & 3 deletions

tests/Builder/UpdateStatementTest.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,7 @@ public function testBuilder(): void
2121
$stmt->build()
2222
);
2323
/* Assertion 2 */
24-
$parser = new Parser(
25-
'update user u join user_detail ud on u.id = ud.user_id set ud.ip =\'33\' where u.id = 1'
26-
);
24+
$parser = new Parser('update user u join user_detail ud on u.id = ud.user_id set ud.ip =\'33\' where u.id = 1');
2725
$stmt = $parser->statements[0];
2826
$this->assertEquals(
2927
'UPDATE user AS `u` SET ud.ip = \'33\' WHERE u.id = 1',

tests/Parser/TransactionStatementTest.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ public function transactionProvider(): array
3838
['parser/parseTransaction2'],
3939
['parser/parseTransaction3'],
4040
['parser/parseTransaction4'],
41+
['parser/parseTransaction5'],
42+
['parser/parseTransaction6'],
43+
['parser/parseTransaction7'],
4144
['parser/parseTransactionErr1'],
4245
];
4346
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
BEGIN;
2+
INSERT INTO t2 VALUES (3);
3+
SAVEPOINT my_savepoint;
4+
INSERT INTO t2 VALUES (4);
5+
RELEASE SAVEPOINT my_savepoint;
6+
COMMIT;

0 commit comments

Comments
 (0)