File tree Expand file tree Collapse file tree 2 files changed +10
-3
lines changed
Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -265,7 +265,7 @@ public function setFlushThreshold($threshold): self
265265 throw new TypeError (sprintf (__METHOD__ .'() expects 1 Argument to be null or an integer %s given ' , gettype ($ threshold )));
266266 }
267267
268- if (null !== $ threshold && 1 >= $ threshold ) {
268+ if (null !== $ threshold && 1 > $ threshold ) {
269269 throw new Exception (__METHOD__ .'() expects 1 Argument to be null or a valid integer greater or equal to 1 ' );
270270 }
271271
Original file line number Diff line number Diff line change @@ -40,10 +40,17 @@ public function tearDown()
4040 */
4141 public function testflushThreshold ()
4242 {
43- $ this ->expectException (Exception::class);
4443 $ this ->csv ->setFlushThreshold (12 );
4544 $ this ->assertSame (12 , $ this ->csv ->getFlushThreshold ());
46- $ this ->csv ->setFlushThreshold (12 );
45+ }
46+
47+ /**
48+ * @covers ::setFlushThreshold
49+ */
50+ public function testflushThresholdThrowsException ()
51+ {
52+ $ this ->csv ->setFlushThreshold (1 );
53+ $ this ->expectException (Exception::class);
4754 $ this ->csv ->setFlushThreshold (0 );
4855 }
4956
You can’t perform that action at this time.
0 commit comments