You are here

public function BuildTestBase::assertCommandSuccessful in Drupal 9

Same name and namespace in other branches
  1. 8 core/tests/Drupal/BuildTests/Framework/BuildTestBase.php \Drupal\BuildTests\Framework\BuildTestBase::assertCommandSuccessful()

Asserts that the last command ran without error.

This assertion checks whether the last command returned an exit code of 0.

If you need to assert a different exit code, then you can use executeCommand() and perform a different assertion on the process object.

6 calls to BuildTestBase::assertCommandSuccessful()
BuildTestTest::testWorkspace in core/tests/Drupal/BuildTests/Framework/Tests/BuildTestTest.php
Ensure that workspaces work.
ComposerProjectTemplatesTest::assertDrupalVersion in core/tests/Drupal/BuildTests/Composer/Template/ComposerProjectTemplatesTest.php
Assert that the VERSION constant in Drupal.php is the expected value.
ComposerProjectTemplatesTest::getLowestDependencyStability in core/tests/Drupal/BuildTests/Composer/Template/ComposerProjectTemplatesTest.php
Returns the stability of the least stable dependency.
ComposerProjectTemplatesTest::makeVendorPackage in core/tests/Drupal/BuildTests/Composer/Template/ComposerProjectTemplatesTest.php
Creates a test package that points to all the projects in vendor.
ComposerProjectTemplatesTest::testTemplateCreateProject in core/tests/Drupal/BuildTests/Composer/Template/ComposerProjectTemplatesTest.php
@dataProvider provideTemplateCreateProject

... See full list

File

core/tests/Drupal/BuildTests/Framework/BuildTestBase.php, line 286

Class

BuildTestBase
Provides a workspace to test build processes.

Namespace

Drupal\BuildTests\Framework

Code

public function assertCommandSuccessful() {
  return $this
    ->assertCommandExitCode(0);
}