Skip to content

Commit

Permalink
lexik#15 - removing unneeded env option
Browse files Browse the repository at this point in the history
  • Loading branch information
marek committed Sep 27, 2023
1 parent 1595e0e commit e2e76a6
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
1 change: 0 additions & 1 deletion Cron/DumpFile.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ private function render(): string
'user' => $this->configuration->getUser(),
'absolute_path' => $this->configuration->getAbsolutePath(),
'php_version' => $this->configuration->getPhpVersion(),
'env' => $this->env,
'mailto' => $this->configuration->getMailto(),
]);
}
Expand Down
2 changes: 1 addition & 1 deletion Resources/views/template.txt.twig
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ MAILTO="{{ mailto }}"
{% for cron in crons %}
# {{ cron.name }}

{{ cron.expression }} {{ user }} {{ php_version }} {{ absolute_path }} {{ cron.command }} --env={{ env }}
{{ cron.expression }} {{ user }} {{ php_version }} {{ absolute_path }} {{ cron.command }}

{% endfor %}
4 changes: 2 additions & 2 deletions Tests/Functional/Command/GenerateCronFileCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public function testGenerateFullConfiguration()

$this->assertSame(0, $tester->execute(['env-mode' => 'staging']));

$expected = '* * * * * project_staging php7.3 path/to/staging app:test --env=staging';
$expected = '* * * * * project_staging php7.3 path/to/staging app:test';

$cacheDir = $kernel->getContainer()->getParameter('kernel.cache_dir').'/cron_test';

Expand Down Expand Up @@ -52,7 +52,7 @@ public function testDryRun()
$this->assertStringContainsString('[OK] Dry run generated', $tester->getDisplay());
$this->assertStringContainsString('# send email', $tester->getDisplay());
$this->assertStringContainsString(
'* * * * * project_staging php7.3 path/to/staging app:test --env=staging',
'* * * * * project_staging php7.3 path/to/staging app:test',
$tester->getDisplay()
);
}
Expand Down

0 comments on commit e2e76a6

Please sign in to comment.