Skip to content

Commit 7070665

Browse files
authored
Test specified lists (#688)
1 parent dffa34b commit 7070665

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

tests/default/data/pdo-prepare.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,20 @@ public function unspecifiedList(PDO $pdo, array $idsToUpdate, string $time)
9595
assertType('PDOStatement<array{adaid: int<-32768, 32767>, 0: int<-32768, 32767>}>', $stmt);
9696
}
9797

98+
/**
99+
* @param list<positive-int> $idsToUpdate
100+
*/
101+
public function specifiedList(PDO $pdo, array $idsToUpdate, string $time)
102+
{
103+
$query = 'SELECT adaid FROM ada WHERE adaid IN (:ids) AND email LIKE :time';
104+
$stmt = $pdo->prepare($query);
105+
$stmt->execute([
106+
'ids' => $idsToUpdate,
107+
'time' => $time,
108+
]);
109+
assertType('PDOStatement<array{adaid: int<-32768, 32767>, 0: int<-32768, 32767>}>', $stmt);
110+
}
111+
98112
/**
99113
* @param number $idsToUpdate
100114
*/

0 commit comments

Comments
 (0)