/** * @dataProvider providerSetIdTypeAffectsSearchIndex * * @param string $idType * @param string|null $expectedSearchIndex */ public function testSetIdTypeAffectsSearchIndex($idType, $expectedSearchIndex) { $lookup = new Lookup(); $lookup->setIdType($idType); $parameters = $lookup->getOperationParameter(); if ($expectedSearchIndex === null) { $this->assertArrayNotHasKey('SearchIndex', $parameters); } else { $this->assertSame($expectedSearchIndex, $parameters['SearchIndex']); } }