- public static function provider_queueLists() {
- return array(
- array( 'queueRand', false, 'Random queue without ack()' ),
- array( 'queueRandTTL', true, 'Random queue with ack()' ),
- array( 'queueTimestamp', false, 'Time ordered queue without ack()' ),
- array( 'queueTimestampTTL', true, 'Time ordered queue with ack()' ),
- array( 'queueFifo', false, 'FIFO ordered queue without ack()' ),
- array( 'queueFifoTTL', true, 'FIFO ordered queue with ack()' )
+ /**
+ * @covers JobQueue
+ */
+ public function testQueueAggregateTable() {
+ $queue = $this->queueFifo;
+ if ( !$queue || !method_exists( $queue, 'getServerQueuesWithJobs' ) ) {
+ $this->markTestSkipped();
+ }
+
+ $this->assertNotContains(
+ [ $queue->getType(), $queue->getWiki() ],
+ $queue->getServerQueuesWithJobs(),
+ "Null queue not in listing"
+ );
+
+ $queue->push( $this->newJob( 0 ) );
+
+ $this->assertContains(
+ [ $queue->getType(), $queue->getWiki() ],
+ $queue->getServerQueuesWithJobs(),
+ "Null queue in listing"