Beispiel #1
0
 /**
  * Install Magento via web interface.
  *
  * @param AssertAgreementTextPresent $assertLicense
  * @param array $configData
  * @param array $install [optional]
  * @return array
  */
 public function test(AssertAgreementTextPresent $assertLicense, array $configData, array $install = [])
 {
     // Preconditions:
     $installConfig = $this->prepareInstallFixture($configData, $install);
     $user = $this->fixtureFactory->createByCode('user', ['dataSet' => 'default']);
     // Steps:
     $this->installPage->open();
     $this->installPage->getLicenseBlock()->acceptLicenseAgreement();
     // Verify license agreement.
     $assertLicense->processAssert($this->installPage);
     $this->installPage->getContinueBlock()->continueInstallation();
     $this->installWizardLocale->getLocalizationForm()->fill($installConfig);
     $this->installWizardLocale->getContinueBlock()->continueInstallation();
     $this->installWizardConfig->getConfigurationForm()->fill($installConfig);
     $this->installWizardConfig->getContinueBlock()->continueInstallation();
     $this->installWizardAdministrator->getPersonalInformationForm()->fill($user);
     $this->installWizardAdministrator->getContinueBlock()->continueInstallation();
     return ['user' => $user];
 }
 /**
  * Assert that part of license agreement text is present on Terms & Agreement page.
  *
  * @param Install $installPage
  * @return void
  */
 public function processAssert(Install $installPage)
 {
     \PHPUnit_Framework_Assert::assertContains(self::LICENSE_AGREEMENT_TEXT, $installPage->getLicenseBlock()->getLicense(), 'License agreement text is absent.');
 }