Skip to content

Commit

Permalink
Add drush cr before code update (#18)
Browse files Browse the repository at this point in the history
  • Loading branch information
mtodor authored and dbosen committed Feb 19, 2018
1 parent 004d9ce commit ff08508
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions scripts/update-tester.php
Original file line number Diff line number Diff line change
Expand Up @@ -177,14 +177,20 @@ public function testUpdate(
}
$updatePackages->run();

$absoluteDestinationDocroot = DocrootResolver::getDocroot($absoluteDestination);

// Run "drush cr" before updating code.
$drushCmd = $this->task(Drush::class);
$drushCmd->dir($absoluteDestinationDocroot);
$drushCmd->arg('cache-rebuild');
$drushCmd->run();

/** @var \Robo\Task\Composer\Update $composerUpdate */
$composerUpdate = $this->task(Update::class);
$composerUpdate->dir($absoluteDestination);
$composerUpdate->option('no-interaction')->option('no-dev');
$composerUpdate->run();

$absoluteDestinationDocroot = DocrootResolver::getDocroot($absoluteDestination);

/** @var \Thunder\UpdateTester\Exec\Drush $drushCmd */
$drushCmd = $this->task(Drush::class);
$drushCmd->dir($absoluteDestinationDocroot);
Expand Down

0 comments on commit ff08508

Please sign in to comment.