getVatNumber() public method

Retrieves the VAT number from a company within the European Union
public getVatNumber ( ) : string
return string
Example #1
0
 /**
  * @dataProvider validationProvider
  */
 public function testCanCreateResponseWithArrayAtConstruct($validCheck)
 {
     $response = $this->createViesResponseArray($validCheck);
     $checkVatResponse = new CheckVatResponse($response);
     $this->assertSame($response['countryCode'], $checkVatResponse->getCountryCode());
     $this->assertSame($response['vatNumber'], $checkVatResponse->getVatNumber());
     $this->assertSame($response['requestDate'], $checkVatResponse->getRequestDate()->format(CheckVatResponse::VIES_DATETIME_FORMAT));
     $this->assertSame($response['valid'], $checkVatResponse->isValid());
     $this->assertSame($response['traderName'], $checkVatResponse->getName());
     $this->assertSame($response['traderAddress'], $checkVatResponse->getAddress());
     $this->assertSame($response['requestIdentifier'], $checkVatResponse->getIdentifier());
 }