/**
  * {@inheritdoc}
  */
 public function get($type)
 {
     try {
         return parent::get($type);
     } catch (NonExistingServiceException $e) {
         return $this->defaultResolver;
     }
 }
 function let(ServiceRegistry $calculators, CalculatorInterface $calculator)
 {
     $calculators->get('default')->willReturn($calculator);
     $this->beConstructedWith($calculators);
 }
 /**
  * {@inheritdoc}
  */
 public function calculate($base, TaxRateInterface $rate)
 {
     /** @var CalculatorInterface $calculator */
     $calculator = $this->calculatorsRegistry->get($rate->getCalculator());
     return $calculator->calculate($base, $rate);
 }