Allow "clear" only env configuration

This commit is contained in:
Adam Miribyan
2023-01-28 17:19:07 +01:00
parent c23928348b
commit afefd32379
2 changed files with 9 additions and 1 deletions

View File

@@ -105,6 +105,14 @@ class ConfigurationTest < ActiveSupport::TestCase
ENV["PASSWORD"] = nil
end
test "env args with only clear" do
config = Mrsk::Configuration.new(@deploy.tap { |c| c.merge!({
env: { "clear" => { "PORT" => "3000" } }
}) })
assert_equal [ "-e", "PORT=3000" ], config.env_args
end
test "env args with only secrets" do
ENV["PASSWORD"] = "secret123"
config = Mrsk::Configuration.new(@deploy.tap { |c| c.merge!({