You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -42,7 +39,7 @@ test(function() use ($context, $driver) { // test duplicated table names throw e
42
39
43
40
Assert::exception(function() use ($sqlBuilder) { // reserved by base table name
44
41
$sqlBuilder->addAlias(':book', 'author');
45
-
}, Nette\InvalidArgumentException::class, "Table alias 'author' from chain ':book' is already in use by chain 'author'. Please add/change alias for one of them.");
42
+
}, Nette\InvalidArgumentException::class, "Table alias 'author' from chain ':book' is already in use by chain '$authorTable'. Please add/change alias for one of them.");
46
43
47
44
Assert::exception(function() use ($sqlBuilder) {
48
45
$sqlBuilder->addAlias(':book', 'book1');
@@ -54,6 +51,12 @@ test(function() use ($context, $driver) { // test duplicated table names throw e
54
51
$joins = [];
55
52
$sqlBuilder->parseJoins($joins, $query);
56
53
}, Nette\InvalidArgumentException::class, "Table alias 'tag' from chain '.book1:book_tag.tag' is already in use by chain ':book'. Please add/change alias for one of them.");
54
+
55
+
Assert::exception(function() use ($sqlBuilder) {
56
+
$query = 'WHERE :book(translator).id IS NULL AND :book.id IS NULL';
57
+
$joins = [];
58
+
$sqlBuilder->parseJoins($joins, $query);
59
+
}, Nette\InvalidArgumentException::class, "Table alias 'book' from chain ':book' is already in use by chain ':book(translator)'. Please add/change alias for one of them.");
0 commit comments