function it_gets_random_ids_from_a_table(TableFetcher $tableFetcher) { $take = 4; $randomIds = [3, 6, 7, 2]; $table = 'images'; $tableFetcher->getRandomIds($table, $take)->shouldBeCalled()->willReturn($randomIds); $this->getRandomIdsFromTable($table, $take)->shouldReturn($randomIds); }
/** * @inheritdoc */ public function getRandomIdsFromTable($table, $take) { return $this->db->getRandomIds($table, $take); }