src/Robo/Commands/Validate/PhpcsCommand.php
public function sniffFileSets() {
    $bin = $this->getConfigValue('composer.bin');
    $result = $this->taskExecStack()
      ->dir($this->getConfigValue('repo.root'))
      ->exec("$bin/phpcs")
      ->run();
    $exit_code = $result->getExitCode();
    if ($exit_code) {
      if ($this->input()->isInteractive()) {
        $this->fixViolationsInteractively();
        throw new BltException("Initial execution of PHPCS failed. Re-run now that PHPCBF has fixed some violations.");
      }
      else {
        $this->logger->notice('Try running `blt source:fix:php-standards` to automatically fix standards violations.');
        throw new BltException("PHPCS failed.");
      }
    }
  }
public function sniffFileSets() {
    $bin = $this->getConfigValue('composer.bin');
    $result = $this->taskExecStack()
      ->dir($this->getConfigValue('repo.root'))
      ->exec("$bin/phpcs")
      ->run();
    $exit_code = $result->getExitCode();
    if ($exit_code) {
      if ($this->input()->isInteractive()) {
        $this->fixViolationsInteractively();
        throw new BltException("Initial execution of PHPCS failed. Re-run now that PHPCBF has fixed some violations.");
      }
      else {
        $this->logger->notice('Try running `blt source:fix:php-standards` to automatically fix standards violations.');
        throw new BltException("PHPCS failed.");
      }
    }
  }
public function sniffFileSets ( ) { $ bin = $ this -> getConfigValue ( 'composer.bin' ) ; $ result = $ this -> taskExecStack ( ) -> dir ( $ this -> getConfigValue ( 'repo.root' ) ) -> exec ( "$bin/phpcs" ) -> run ( ) ; $ exit_code = $ result -> getExitCode ( ) ; if ( $ exit_code ) { if ( $ this -> input ( ) -> isInteractive ( ) ) { $ this -> fixViolationsInteractively ( ) ; throw new BltException ( "Initial execution of PHPCS failed. Re-run now that PHPCBF has fixed some violations." ) ; } else { $ this -> logger -> notice ( 'Try running `blt source:fix:php-standards` to automatically fix standards violations.' ) ; throw new BltException ( "PHPCS failed." ) ; } } }
Executes PHP Code Sniffer against all phpcs.filesets files.

By default, these include custom themes, modules, and tests.

@command tests:phpcs:sniff:all

@aliases tpsa phpcs tests:phpcs:sniff validate:phpcs
Executes PHP Code Sniffer against all phpcs . filesets files .