Chris@0: container->get('update.root') . '/' . DrupalKernel::findSitePath($request); Chris@0: $this->container->set('update.root', $update_root); Chris@0: \Drupal::setContainer($this->container); Chris@0: Chris@0: // Create the directories within the root path within which the Update Chris@0: // Manager will install projects. Chris@0: foreach (drupal_get_updaters() as $updater_info) { Chris@0: $updater = $updater_info['class']; Chris@0: $install_directory = $update_root . '/' . $updater::getRootDirectoryRelativePath(); Chris@0: if (!is_dir($install_directory)) { Chris@0: mkdir($install_directory); Chris@0: } Chris@0: } Chris@0: } Chris@0: Chris@0: /** Chris@0: * Refreshes the update status based on the desired available update scenario. Chris@0: * Chris@0: * @param $xml_map Chris@0: * Array that maps project names to availability scenarios to fetch. The key Chris@0: * '#all' is used if a project-specific mapping is not defined. Chris@0: * @param $url Chris@0: * (optional) A string containing the URL to fetch update data from. Chris@0: * Defaults to 'update-test'. Chris@0: * Chris@0: * @see \Drupal\update_test\Controller\UpdateTestController::updateTest() Chris@0: */ Chris@0: protected function refreshUpdateStatus($xml_map, $url = 'update-test') { Chris@0: // Tell the Update Manager module to fetch from the URL provided by Chris@0: // update_test module. Chris@0: $this->config('update.settings')->set('fetch.url', Url::fromUri('base:' . $url, ['absolute' => TRUE])->toString())->save(); Chris@0: // Save the map for UpdateTestController::updateTest() to use. Chris@0: $this->config('update_test.settings')->set('xml_map', $xml_map)->save(); Chris@0: // Manually check the update status. Chris@0: $this->drupalGet('admin/reports/updates'); Chris@0: $this->clickLink(t('Check manually')); Chris@0: } Chris@0: Chris@0: /** Chris@0: * Runs a series of assertions that are applicable to all update statuses. Chris@0: */ Chris@0: protected function standardTests() { Chris@0: $this->assertRaw('