/**
  * @param array $billingData
  * @param array $expectedResult
  *
  * @dataProvider dataProviderBuild
  */
 public function testBuild($billingData, $expectedResult)
 {
     $billingMock = $this->getBillingMock($billingData);
     $this->paymentDOMock->expects(static::once())->method('getOrder')->willReturn($this->orderMock);
     $this->orderMock->expects(static::once())->method('getBillingAddress')->willReturn($billingMock);
     $buildSubject = ['payment' => $this->paymentDOMock];
     $this->subjectReaderMock->expects(self::once())->method('readPayment')->with($buildSubject)->willReturn($this->paymentDOMock);
     self::assertEquals($expectedResult, $this->builder->build($buildSubject));
 }
 protected function setUp()
 {
     $this->initOrderMock();
     $this->paymentDO = $this->getMockBuilder(PaymentDataObjectInterface::class)->disableOriginalConstructor()->setMethods(['getOrder', 'getPayment'])->getMock();
     $this->paymentDO->expects(static::once())->method('getOrder')->willReturn($this->order);
     $this->configMock = $this->getMockBuilder(Config::class)->setMethods(['isVerify3DSecure', 'getThresholdAmount', 'get3DSecureSpecificCountries'])->disableOriginalConstructor()->getMock();
     $this->subjectReaderMock = $this->getMockBuilder(SubjectReader::class)->disableOriginalConstructor()->getMock();
     $this->builder = new ThreeDSecureDataBuilder($this->configMock, $this->subjectReaderMock);
 }