File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -94,6 +94,9 @@ public function testFetchRow() : void
9494 $ result = static ::$ database ->query ('SELECT * FROM `t1` ' );
9595 self ::assertSame (1 , $ result ->fetchRow (0 )->c1 );
9696 self ::assertSame (4 , $ result ->fetchRow (3 )->c1 );
97+ $ this ->expectException (\OutOfRangeException::class);
98+ $ this ->expectExceptionMessage ('Invalid cursor offset: 5 ' );
99+ $ result ->fetchRow (5 );
97100 }
98101
99102 public function testFetchRowFree () : void
@@ -106,6 +109,9 @@ public function testFetchArrayRow() : void
106109 $ result = static ::$ database ->query ('SELECT * FROM `t1` ' );
107110 self ::assertSame (1 , $ result ->fetchArrayRow (0 )['c1 ' ]);
108111 self ::assertSame (4 , $ result ->fetchArrayRow (3 )['c1 ' ]);
112+ $ this ->expectException (\OutOfRangeException::class);
113+ $ this ->expectExceptionMessage ('Invalid cursor offset: 5 ' );
114+ $ result ->fetchArrayRow (5 );
109115 }
110116
111117 public function testFetchArrayRowFree () : void
You can’t perform that action at this time.
0 commit comments