Skip to content

Commit

Permalink
Merge pull request #445 from platanus/fix-env-vars-test
Browse files Browse the repository at this point in the history
Fixes failing tests
  • Loading branch information
difernandez authored Jun 20, 2023
2 parents 394ad72 + c242e0d commit b0a2a50
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/potassium/recipes/mailer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def config_environments
RUBY
application asset_host_prod, env: "production"
mailer_config = <<~RUBY
require Rails.root.join("config", "mailer")
require Rails.root.join("config/mailer")
RUBY

prepend_file "config/environments/production.rb", mailer_config
Expand Down
6 changes: 6 additions & 0 deletions spec/features/environment_variables_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
RSpec.describe 'EnvironmentVariables' do
let(:environment_variables) { IO.read("#{project_path}/lib/environment_variables.rb") }

before :all do
drop_dummy_database
remove_project_directory
create_dummy_project
end

it 'creates a .env.test file' do
expect(File.exists?("#{project_path}/.env.test")).to eq(true)
end
Expand Down
2 changes: 1 addition & 1 deletion spec/features/mailer_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
end
let(:mailer_config_text) do
<<~RUBY
require Rails.root.join("config", "mailer")
require Rails.root.join("config/mailer")
RUBY
end

Expand Down

0 comments on commit b0a2a50

Please sign in to comment.