/** * @see PHPUnit_Framework_TestCase::setUp() */ protected function setUp() { $this->pluginId = 'medra'; // Retrieve and check configuration. (We're in a chicken // and egg situation: This means that we cannot call // parent::setUp() at this point so we have to retrieve // the base URL here although it will be retrieved again // in the parent class.) $baseUrl = Config::getVar('debug', 'webtest_base_url'); $medraPassword = Config::getVar('debug', 'webtest_medra_pw'); if (empty($baseUrl) || empty($medraPassword)) { $this->markTestSkipped('Please set webtest_base_url and webtest_medra_pw in your ' . 'config.php\'s [debug] section to the base url of your test server ' . 'and the password of your Medra test account.'); } $this->pages = array('index' => $baseUrl . '/index.php/test/manager/importexport/plugin/MedraExportPlugin', 'settings' => $baseUrl . '/index.php/test/manager/plugin/importexport/MedraExportPlugin/settings'); $this->defaultPluginSettings = array('username' => self::TEST_ACCOUNT, 'password' => $medraPassword, 'registrantName' => 'Registrant', 'fromCompany' => 'From Company', 'fromName' => 'From Person', 'fromEmail' => '*****@*****.**', 'publicationCountry' => 'US', 'exportIssuesAs' => O4DOI_ISSUE_AS_WORK); parent::setUp('1749'); }
/** * @see PHPUnit_Framework_TestCase::setUp() */ protected function setUp() { $this->pluginId = 'datacite'; // Retrieve and check configuration. (We're in a chicken // and egg situation: This means that we cannot call // parent::setUp() at this point so we have to retrieve // the base URL here although it will be retrieved again // in the parent class.) $baseUrl = Config::getVar('debug', 'webtest_base_url'); $this->dcPassword = Config::getVar('debug', 'webtest_datacite_pw'); if (empty($baseUrl) || empty($this->dcPassword)) { $this->markTestSkipped('Please set webtest_base_url and webtest_datacite_pw in your ' . 'config.php\'s [debug] section to the base url of your test server ' . 'and the password of your DataCite test account.'); } $indexPage = $baseUrl . '/index.php/test/manager/importexport/plugin/DataciteExportPlugin'; $this->pages = array('index' => $indexPage, 'settings' => $baseUrl . '/index.php/test/manager/plugin/importexport/DataciteExportPlugin/settings'); $this->defaultPluginSettings = array('username' => self::TEST_ACCOUNT, 'password' => $this->dcPassword); parent::setUp('10.5072'); $this->configurePlugin(); }