diff --git a/app/Console/Commands/GetVersion.php b/app/Console/Commands/GetVersion.php new file mode 100644 index 00000000000..9fecfdb3ecd --- /dev/null +++ b/app/Console/Commands/GetVersion.php @@ -0,0 +1,30 @@ +line(config('monica.app_version')); + } +} diff --git a/tests/Unit/Commands/GetVersionTest.php b/tests/Unit/Commands/GetVersionTest.php new file mode 100644 index 00000000000..0cdb7c894a3 --- /dev/null +++ b/tests/Unit/Commands/GetVersionTest.php @@ -0,0 +1,18 @@ + '1.0.0']); + + $this->artisan('monica:getversion') + ->expectsOutput('1.0.0') + ->assertExitCode(0); + } +}