Skip to content

Commit 26e8f3d

Browse files
author
Spencer Rinehart
committed
Enable strict code coverage.
1 parent d17ef86 commit 26e8f3d

2 files changed

Lines changed: 28 additions & 1 deletion

File tree

phpunit.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<phpunit colors="true" forceCoversAnnotation="true">
1+
<phpunit colors="true" forceCoversAnnotation="true" strict="true">
22
<testsuite name="Unit Tests">
33
<directory>./tests</directory>
44
</testsuite>

tests/QueueTest.php

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
/**
66
* @coversDefaultClass \DominionEnterprises\Mongo\Queue
77
* @covers ::<private>
8+
* @uses \DominionEnterprises\Mongo\Queue::__construct
89
*/
910
final class QueueTest extends \PHPUnit_Framework_TestCase
1011
{
@@ -199,6 +200,7 @@ public function ensureCountIndexWithNonBoolIncludeRunning()
199200
/**
200201
* @test
201202
* @covers ::get
203+
* @uses \DominionEnterprises\Mongo\Queue::send
202204
*/
203205
public function getByBadQuery()
204206
{
@@ -233,6 +235,7 @@ public function getWithNonIntPollDuration()
233235
/**
234236
* @test
235237
* @covers ::get
238+
* @uses \DominionEnterprises\Mongo\Queue::send
236239
*/
237240
public function getWithNegativePollDuration()
238241
{
@@ -263,6 +266,7 @@ public function getWithNonIntRunningResetDuration()
263266
/**
264267
* @test
265268
* @covers ::get
269+
* @uses \DominionEnterprises\Mongo\Queue::send
266270
*/
267271
public function getByFullQuery()
268272
{
@@ -282,6 +286,7 @@ public function getByFullQuery()
282286
/**
283287
* @test
284288
* @covers ::get
289+
* @uses \DominionEnterprises\Mongo\Queue::send
285290
*/
286291
public function getBySubDocQuery()
287292
{
@@ -300,6 +305,7 @@ public function getBySubDocQuery()
300305
/**
301306
* @test
302307
* @covers ::get
308+
* @uses \DominionEnterprises\Mongo\Queue::send
303309
*/
304310
public function getBeforeAck()
305311
{
@@ -318,6 +324,7 @@ public function getBeforeAck()
318324
/**
319325
* @test
320326
* @covers ::get
327+
* @uses \DominionEnterprises\Mongo\Queue::send
321328
*/
322329
public function getWithCustomPriority()
323330
{
@@ -341,6 +348,7 @@ public function getWithCustomPriority()
341348
/**
342349
* @test
343350
* @covers ::get
351+
* @uses \DominionEnterprises\Mongo\Queue::send
344352
*/
345353
public function getWithTimeBasedPriority()
346354
{
@@ -364,6 +372,9 @@ public function getWithTimeBasedPriority()
364372
/**
365373
* @test
366374
* @covers ::get
375+
* @uses \DominionEnterprises\Mongo\Queue::send
376+
* @uses \DominionEnterprises\Mongo\Queue::ackSend
377+
* @uses \DominionEnterprises\Mongo\Queue::requeue
367378
*/
368379
public function getWithTimeBasedPriorityWithOldTimestamp()
369380
{
@@ -407,6 +418,7 @@ public function getWait()
407418
/**
408419
* @test
409420
* @covers ::get
421+
* @uses \DominionEnterprises\Mongo\Queue::send
410422
*/
411423
public function earliestGet()
412424
{
@@ -424,6 +436,7 @@ public function earliestGet()
424436
/**
425437
* @test
426438
* @covers ::get
439+
* @uses \DominionEnterprises\Mongo\Queue::send
427440
*/
428441
public function resetStuck()
429442
{
@@ -471,6 +484,8 @@ public function countWithNonStringKey()
471484
/**
472485
* @test
473486
* @covers ::count
487+
* @uses \DominionEnterprises\Mongo\Queue::get
488+
* @uses \DominionEnterprises\Mongo\Queue::send
474489
*/
475490
public function testCount()
476491
{
@@ -494,6 +509,8 @@ public function testCount()
494509
/**
495510
* @test
496511
* @covers ::ack
512+
* @uses \DominionEnterprises\Mongo\Queue::get
513+
* @uses \DominionEnterprises\Mongo\Queue::send
497514
*/
498515
public function ack()
499516
{
@@ -522,6 +539,8 @@ public function ackBadArg()
522539
/**
523540
* @test
524541
* @covers ::ackSend
542+
* @uses \DominionEnterprises\Mongo\Queue::get
543+
* @uses \DominionEnterprises\Mongo\Queue::send
525544
*/
526545
public function ackSend()
527546
{
@@ -598,6 +617,8 @@ public function ackSendWithNonBoolNewTimestamp()
598617
/**
599618
* @test
600619
* @covers ::ackSend
620+
* @uses \DominionEnterprises\Mongo\Queue::get
621+
* @uses \DominionEnterprises\Mongo\Queue::send
601622
*/
602623
public function ackSendWithHighEarliestGet()
603624
{
@@ -629,6 +650,8 @@ public function ackSendWithHighEarliestGet()
629650
/**
630651
* @test
631652
* @covers ::ackSend
653+
* @uses \DominionEnterprises\Mongo\Queue::get
654+
* @uses \DominionEnterprises\Mongo\Queue::send
632655
*/
633656
public function ackSendWithLowEarliestGet()
634657
{
@@ -660,6 +683,9 @@ public function ackSendWithLowEarliestGet()
660683
/**
661684
* @test
662685
* @covers ::requeue
686+
* @uses \DominionEnterprises\Mongo\Queue::get
687+
* @uses \DominionEnterprises\Mongo\Queue::ackSend
688+
* @uses \DominionEnterprises\Mongo\Queue::send
663689
*/
664690
public function requeue()
665691
{
@@ -680,6 +706,7 @@ public function requeue()
680706
/**
681707
* @test
682708
* @covers ::requeue
709+
* @uses \DominionEnterprises\Mongo\Queue::ackSend
683710
* @expectedException \InvalidArgumentException
684711
*/
685712
public function requeueBadArg()

0 commit comments

Comments
 (0)