mirror of
https://github.com/laravel/valet.git
synced 2026-02-06 00:40:06 +01:00
Tweak status output and install output
This commit is contained in:
@@ -24,7 +24,7 @@ public function check(): array
|
|||||||
$isValid = false;
|
$isValid = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return ['description' => $check['description'], 'success' => $thisIsValid ? 'True' : 'False'];
|
return ['description' => $check['description'], 'success' => $thisIsValid ? 'Yes' : 'No'];
|
||||||
});
|
});
|
||||||
|
|
||||||
return [
|
return [
|
||||||
|
|||||||
10
cli/app.php
10
cli/app.php
@@ -52,11 +52,17 @@ function (ConsoleCommandEvent $event) {
|
|||||||
$app->command('install', function (OutputInterface $output) {
|
$app->command('install', function (OutputInterface $output) {
|
||||||
Nginx::stop();
|
Nginx::stop();
|
||||||
|
|
||||||
|
output(PHP_EOL);
|
||||||
Configuration::install();
|
Configuration::install();
|
||||||
|
output(PHP_EOL);
|
||||||
Nginx::install();
|
Nginx::install();
|
||||||
|
output(PHP_EOL);
|
||||||
PhpFpm::install();
|
PhpFpm::install();
|
||||||
|
output(PHP_EOL);
|
||||||
DnsMasq::install(Configuration::read()['tld']);
|
DnsMasq::install(Configuration::read()['tld']);
|
||||||
|
output(PHP_EOL);
|
||||||
Nginx::restart();
|
Nginx::restart();
|
||||||
|
output(PHP_EOL);
|
||||||
Valet::symlinkToUsersBin();
|
Valet::symlinkToUsersBin();
|
||||||
|
|
||||||
output(PHP_EOL.'<info>Valet installed successfully!</info>');
|
output(PHP_EOL.'<info>Valet installed successfully!</info>');
|
||||||
@@ -80,9 +86,9 @@ function (ConsoleCommandEvent $event) {
|
|||||||
|
|
||||||
if ($status['success']) {
|
if ($status['success']) {
|
||||||
return Command::SUCCESS;
|
return Command::SUCCESS;
|
||||||
} else {
|
|
||||||
return Command::FAILURE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return Command::FAILURE;
|
||||||
})->descriptions('Output the status of Valet and its installed services and config.');
|
})->descriptions('Output the status of Valet and its installed services and config.');
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -148,7 +148,7 @@ public function test_status_command_succeeding()
|
|||||||
$tester->run(['command' => 'status']);
|
$tester->run(['command' => 'status']);
|
||||||
|
|
||||||
$tester->assertCommandIsSuccessful();
|
$tester->assertCommandIsSuccessful();
|
||||||
$this->assertStringNotContainsString('False', $tester->getDisplay());
|
$this->assertStringNotContainsString('No', $tester->getDisplay());
|
||||||
}
|
}
|
||||||
|
|
||||||
public function test_status_command_failing()
|
public function test_status_command_failing()
|
||||||
@@ -174,7 +174,7 @@ public function test_status_command_failing()
|
|||||||
$tester->run(['command' => 'status']);
|
$tester->run(['command' => 'status']);
|
||||||
|
|
||||||
$this->assertNotEquals(0, $tester->getStatusCode());
|
$this->assertNotEquals(0, $tester->getStatusCode());
|
||||||
$this->assertStringContainsString('False', $tester->getDisplay());
|
$this->assertStringContainsString('No', $tester->getDisplay());
|
||||||
}
|
}
|
||||||
|
|
||||||
public function test_parked_command()
|
public function test_parked_command()
|
||||||
|
|||||||
Reference in New Issue
Block a user