function Fixtures::appendOp

Same name in other branches
  1. 9 core/tests/Drupal/Tests/Composer/Plugin/Scaffold/Fixtures.php \Drupal\Tests\Composer\Plugin\Scaffold\Fixtures::appendOp()
  2. 10 core/tests/Drupal/Tests/Composer/Plugin/Scaffold/Fixtures.php \Drupal\Tests\Composer\Plugin\Scaffold\Fixtures::appendOp()
  3. 11.x core/tests/Drupal/Tests/Composer/Plugin/Scaffold/Fixtures.php \Drupal\Tests\Composer\Plugin\Scaffold\Fixtures::appendOp()

Creates an AppendOp fixture.

Parameters

string $project_name: The name of the project to fetch; $package_name is "fixtures/$project_name".

string $source: The name of the asset; path is "assets/$source".

Return value

\Drupal\Composer\Plugin\Scaffold\Operations\AppendOp An append operation object.

File

core/tests/Drupal/Tests/Composer/Plugin/Scaffold/Fixtures.php, line 212

Class

Fixtures
Convenience class for creating fixtures.

Namespace

Drupal\Tests\Composer\Plugin\Scaffold

Code

public function appendOp($project_name, $source) {
    $source_path = $this->sourcePath($project_name, $source);
    return new AppendOp(NULL, $source_path);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.