function BuildTestBase::getComposerRoot
Gets the path to the Composer root directory.
Return value
string The absolute path to the Composer root directory.
2 calls to BuildTestBase::getComposerRoot()
- BuildTestBase::copyCodebase in core/
tests/ Drupal/ BuildTests/ Framework/ BuildTestBase.php  - Copy the current working codebase into a workspace.
 - BuildTestBase::getWorkingPathDrupalRoot in core/
tests/ Drupal/ BuildTests/ Framework/ BuildTestBase.php  - Gets the working path for Drupal core.
 
File
- 
              core/
tests/ Drupal/ BuildTests/ Framework/ BuildTestBase.php, line 625  
Class
- BuildTestBase
 - Provides a workspace to test build processes.
 
Namespace
Drupal\BuildTests\FrameworkCode
public function getComposerRoot() : string {
  $root = InstalledVersions::getRootPackage();
  return realpath($root['install_path']);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.