/** * @dataProvider provideInvalidSenderAddressException */ public function testValidateSenderAddressException($calculatorOptions, $address) { $this->setExpectedException(ViolationException::class, 'Can not send a package from this country.'); $calculator = new AramexHandler($calculatorOptions); $calculator->validateSenderAddress($address); }