Skip to content

Commit

Permalink
Update database migrations and strengthen db smoke tests (maybe-finan…
Browse files Browse the repository at this point in the history
  • Loading branch information
adrienpoly committed Feb 15, 2024
1 parent 3ec9c9b commit 093ddba
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ jobs:
env:
RAILS_ENV: test
DATABASE_URL: postgres://postgres:postgres@localhost:5432
run: bin/rails db:reset
run: bin/rails db:drop db:create db:migrate db:seed

- name: Keep screenshots from failed system tests
uses: actions/upload-artifact@v4
Expand Down
2 changes: 1 addition & 1 deletion db/migrate/20240206031739_replace_money_field.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
class ReplaceMoneyField < ActiveRecord::Migration[7.2]
def change
add_column :accounts, :balance_cents
add_column :accounts, :balance_cents, :integer
change_column :accounts, :balance_cents, :integer, limit: 8

Account.reset_column_information
Expand Down
1 change: 0 additions & 1 deletion db/migrate/20240209174912_redo_money_storage.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ def change
add_column :accounts, :converted_currency, :string, default: "USD"

remove_column :accounts, :balance_cents
remove_column :accounts, :balance_currency
remove_column :accounts, :currency
end
end

0 comments on commit 093ddba

Please sign in to comment.