Skip to content

Commit

Permalink
#15 - removing unneeded env option (#16) (#19)
Browse files Browse the repository at this point in the history
  • Loading branch information
raneomik committed Jul 23, 2024
1 parent 425c75d commit efcfeeb
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 efcfeeb

Please sign in to comment.