/** * @dataProvider provideValidateWeightException */ public function testValidateWeightException($exceptionMessage, $calculatorOptions, $package) { $this->setExpectedException('EsteIt\\ShippingCalculator\\Exception\\InvalidWeightException', $exceptionMessage); $calculator = new AramexCalculatorHandler($calculatorOptions); $calculator->validateWeight($package); }