forked from acquia/blt
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
…4514) * Fixes acquia#4513: updating other inspector uses of drush. * refactoring test use of drush commands. * Adding backwards compatibility string to array conversion for drush and execution. Co-authored-by: Mike Madison <>
- Loading branch information
1 parent
b4dece2
commit 57cf3d7
Showing
13 changed files
with
172 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<?php | ||
|
||
namespace Acquia\Blt\Tests; | ||
|
||
use Acquia\Blt\Robo\Common\StringManipulator; | ||
|
||
/** | ||
* Tests String to Array Conversion for Commands. | ||
*/ | ||
class CommandArrayTest extends BltProjectTestBase { | ||
|
||
public function testStringToArray() { | ||
$string = "site-install minimal --existing-config --ansi -n"; | ||
$command = StringManipulator::commandConvert($string); | ||
$this->assertIsArray($command); | ||
|
||
$keys = $this->getKeys(); | ||
foreach ($keys as $key) { | ||
$result = in_array($key, $command); | ||
$this->assertTrue($result); | ||
} | ||
} | ||
|
||
public function testStringDrush() { | ||
$string = "status --yes"; | ||
$this->drushJson($string); | ||
} | ||
|
||
public function getKeys() { | ||
return [ | ||
"site-install", | ||
"minimal", | ||
"--existing-config", | ||
"--ansi", | ||
"-n", | ||
]; | ||
} | ||
|
||
} |
Oops, something went wrong.