Skip to content

Commit

Permalink
Merge pull request rails#54125 from OuYangJinTing/fix-ci-template
Browse files Browse the repository at this point in the history
Fix DATABASE_URL variable in the ci template
  • Loading branch information
eileencodes authored Jan 6, 2025
2 parents 51bc2db + c2a3ab3 commit 272fb90
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,10 @@ jobs:
- name: Run tests
env:
RAILS_ENV: test
<%- if options[:database] == "mysql" || options[:database] == "trilogy" -%>
<%- if options[:database] == "mysql" -%>
DATABASE_URL: mysql2://127.0.0.1:3306
<%- elsif options[:database] == "trilogy" -%>
DATABASE_URL: trilogy://127.0.0.1:3306
<%- elsif options[:database] == "postgresql" -%>
DATABASE_URL: postgres://postgres:postgres@localhost:5432
<%- end -%>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,10 @@ jobs:
- name: Run tests
env:
RAILS_ENV: test
<%- if options[:database] == "mysql" || options[:database] == "trilogy" -%>
<%- if options[:database] == "mysql" -%>
DATABASE_URL: mysql2://127.0.0.1:3306
<%- elsif options[:database] == "trilogy" -%>
DATABASE_URL: trilogy://127.0.0.1:3306
<%- elsif options[:database] == "postgresql" -%>
DATABASE_URL: postgres://postgres:postgres@localhost:5432
<%- end -%>
Expand All @@ -100,4 +102,3 @@ jobs:
path: ${{ github.workspace }}/tmp/screenshots
if-no-files-found: ignore
<% end -%>

0 comments on commit 272fb90

Please sign in to comment.