From 595cfeff9a936ca58e04529d2051d8a4c724c0f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Muhammed=20K=C4=B1l=C4=B1=C3=A7?= Date: Tue, 6 Feb 2024 22:24:14 +0300 Subject: [PATCH 01/15] Update seeds.rb with sample user (#326) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Update seeds.rb with sample user Signed-off-by: Muhammed Kılıç * Update create with create_or_find_by Co-authored-by: Sebastián Caraballo Signed-off-by: Muhammed Kılıç * Update user create with create_or_find_by Co-authored-by: Sebastián Caraballo Signed-off-by: Muhammed Kılıç * Update seed data * Update README with seed credentials --------- Signed-off-by: Muhammed Kılıç Co-authored-by: Sebastián Caraballo --- README.md | 6 +++++- db/seeds.rb | 8 ++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 769396dd..a2116fe1 100644 --- a/README.md +++ b/README.md @@ -49,7 +49,11 @@ rails db:setup bin/dev ``` -And visit [http://localhost:3000](http://localhost:3000) +And visit [http://localhost:3000](http://localhost:3000) to see the app. +You can use the following credentials to log in: + +- Email: `user@maybe.local` +- Password: `password` ### Email diff --git a/db/seeds.rb b/db/seeds.rb index 4fbd6ed9..396593bd 100644 --- a/db/seeds.rb +++ b/db/seeds.rb @@ -7,3 +7,11 @@ # ["Action", "Comedy", "Drama", "Horror"].each do |genre_name| # MovieGenre.find_or_create_by!(name: genre_name) # end + +# Create the default user +family = Family.create_or_find_by!(name: "The Maybe Family") +puts "Family created: #{family.name}" +user = User.create_or_find_by!( + first_name: "Josh", last_name: "Maybe", email: "user@maybe.local", + password: "password", password_confirmation: "password", family_id: family.id) +puts "User created: #{user.email} for family: #{family.name}" From 3fc4371378a84c751a244d9ebd38c8a59fd14500 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Muhammed=20K=C4=B1l=C4=B1=C3=A7?= Date: Tue, 6 Feb 2024 22:46:06 +0300 Subject: [PATCH 02/15] Ignore DS_Store and devcontainer generated files (#332) --- .gitignore | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.gitignore b/.gitignore index 763dc3f6..7d98173a 100644 --- a/.gitignore +++ b/.gitignore @@ -40,3 +40,10 @@ # Ignore Jetbrains IDEs .idea + +# Ignore macOS specific files +*/.DS_Store +.DS_Store + +# Ignore .devcontainer files +compose-dev.yaml From b8198d17b7139c99d7f65d396f527688f3ae8779 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Muhammed=20K=C4=B1l=C4=B1=C3=A7?= Date: Tue, 6 Feb 2024 22:50:11 +0300 Subject: [PATCH 03/15] Fix accounts title and i18n variable name (#333) --- app/views/layouts/application.html.erb | 6 ++++-- config/locales/views/layout/en.yml | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 80628e29..fd46221a 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -56,8 +56,10 @@
- <%= t('.accounts') %> - <%= link_to new_account_path, class: 'block hover:bg-gray-100 p-2 text-sm font-semibold text-gray-900 flex items-center rounded', title: t('.new_accoount') do %> + <%= link_to accounts_path, class: 'text-xs' do%> + <%= t('.accounts') %> + <% end %> + <%= link_to new_account_path, class: 'block hover:bg-gray-100 p-2 text-sm font-semibold text-gray-900 flex items-center rounded', title: t('.new_account') do %> <%= inline_svg_tag('icon-add.svg', class: 'text-gray-500 fill-current') %> <% end %>
diff --git a/config/locales/views/layout/en.yml b/config/locales/views/layout/en.yml index 85310a0f..780891a5 100644 --- a/config/locales/views/layout/en.yml +++ b/config/locales/views/layout/en.yml @@ -5,7 +5,7 @@ en: accounts: Accounts cash: Cash dashboard: Dashboard - new_accoount: New Account + new_account: New Account auth: or: or privacy_policy: Privacy Policy From ae241c29f0b49d7fbb44164692f97d697559431b Mon Sep 17 00:00:00 2001 From: Zach Gollwitzer Date: Tue, 6 Feb 2024 18:14:52 -0500 Subject: [PATCH 04/15] Improve Local Dev Setup Documentation and Contribution Guidelines (#339) * Update contributing guide and README * Add back syntax highlighting --- CONTRIBUTING.md | 37 +++++++++++++++++++++++++---- README.md | 63 ++++++++++++++++++++++++++----------------------- 2 files changed, 66 insertions(+), 34 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 61209a3d..aab5f572 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -2,12 +2,39 @@ It means so much that you're interested in contributing to Maybe! Seriously. Thank you. The entire community benefits from these contributions! -Before submitting a new issue or PR, check if it already exists in [issues](https://github.com/maybe-finance/maybe/issues) or [PRs](https://github.com/maybe-finance/maybe/pulls) so you have an idea of where things stand. +## House Rules -Then, once you're ready to begin work, submit a draft PR with your high-level plan (or the full solution). +- Before contributing, please check if it already exists in [issues](https://github.com/maybe-finance/maybe/issues) or [PRs](https://github.com/maybe-finance/maybe/pulls) +- Given the speed at which we're moving on the codebase, we don't assign issues or "give" issues to anyone. +- When multiple PRs are submitted for the same issue, we take the one that most succinctly & efficiently solves a given problem and stays within the scope of work. +- Priority is generally given to previous committers as they've proven familiarity with the codebase and product. -Given the speed at which we're moving on the codebase, we don't assign issues or "give" issues to anyone. +## What should I contribute? -When multiple PRs are submitted for the same issue, we take the one that most succinctly & efficiently solves a given problem and stays within the scope of work. +As we are still in the early days of this project, we recommend [heading over to the Wiki](https://github.com/maybe-finance/maybe/wiki) to get a better idea of _what_ to contribute. -Priority is also generally given to previous committers as they've proven familiarity with the codebase and product. +In general, _full features_ that get us closer to [our Vision](https://github.com/maybe-finance/maybe/wiki/Vision) are the most valuable contributions at this stage. + +## Development + +### Setup + +To get setup for local development, you have two options: + +1. [Dev Containers](https://code.visualstudio.com/docs/devcontainers/containers) with VSCode (see the `.devcontainer` folder) +2. Local Development + - [Mac Setup Guide](https://github.com/maybe-finance/maybe/wiki/Mac-Dev-Setup-Guide) + - [Linux Setup Guide](https://github.com/maybe-finance/maybe/wiki/Linux-Dev-Setup-Guide) + - [Windows Setup Guide](https://github.com/maybe-finance/maybe/wiki/Windows-Dev-Setup-Guide) + +### Making a Pull Request + +1. Fork the repo +2. Create your feature branch (`git checkout -b my-new-feature`) +3. Commit your changes (`git commit -am 'Add some feature'`) +4. Push to the branch (`git push origin my-new-feature`) +5. Create new Pull Request, and be sure to check the [Allow edits from maintainers](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/allowing-changes-to-a-pull-request-branch-created-from-a-fork) option while creating your PR. This allows maintainers to collaborate with you on your PR if needed. +6. If possible, [link your pull request to an issue](https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword) by adding the appropriate keyword (e.g. `fixes issue #XXX`) +7. Before requesting a review, please make sure that all [Github Checks](https://docs.github.com/en/rest/checks?apiVersion=2022-11-28) have passed and your branch is up-to-date with the `main` branch. After doing so, request a review and wait for a maintainer's approval. + +All PRs should target the `main` branch. diff --git a/README.md b/README.md index a2116fe1..57e654e3 100644 --- a/README.md +++ b/README.md @@ -26,22 +26,16 @@ We're now building the app in Ruby on Rails. We realize that's a controversial c From the start our focus with this is to make it as easy as possible for you to both contribute to and deploy the app, and this move to Rails is a big part of that. -## Codebase +## Local Development Setup -The codebase is vanilla [Rails](https://rubyonrails.org/) and [Postgres](https://www.postgresql.org/). Quite a simple setup. +### Requirements -## Setup +- Ruby >3 (see `Gemfile`) +- PostgreSQL >9.3 (ideally, latest stable version) -You'll need: +After cloning the repo, the basic setup commands are: -- ruby >3 (specific version is in `Gemfile`) -- postgresql (if using stock `config/database.yml`) - -If you prefer devcontainer, this project supports it (entirely optional). - -Run the following commands after cloning the repo: - -```shell +```sh cd maybe cp .env.example .env bundle install @@ -49,37 +43,48 @@ rails db:setup bin/dev ``` -And visit [http://localhost:3000](http://localhost:3000) to see the app. -You can use the following credentials to log in: +And visit http://localhost:3000 to see the app. You can use the following credentials to log in (generated by DB seed): -- Email: `user@maybe.local` -- Password: `password` +Email: user@maybe.local +Password: password -### Email +For further instructions, see guides below. -In development, we use `letter_opener` to automatically open emails in your browser. However, if you self-host, you'll likely want some basic email sending abilities. +### Setup Guides -You can use any SMTP-based mail service and then simply drop in your SMTP credentials in the `.env` file. +#### Dev Container (optional) -[Resend](https://resend.com) is a great option for personal use as they have a very generous free plan. +This is 100% optional and meant for devs who don't want to worry about installing requirements manually for their platform. You can follow [this guide](https://code.visualstudio.com/docs/devcontainers/containers) to learn more about Dev Containers. + +#### Mac + +Please visit our [Mac dev setup guide](https://github.com/maybe-finance/maybe/wiki/Mac-Dev-Setup-Guide). + +#### Linux + +Please visit our [Linux dev setup guide](https://github.com/maybe-finance/maybe/wiki/Linux-Dev-Setup-Guide). + +#### Windows + +Please visit our [Windows dev setup guide](https://github.com/maybe-finance/maybe/wiki/Windows-Dev-Setup-Guide). + +### Testing Emails + +In development, we use `letter_opener` to automatically open emails in your browser. When an email sends locally, a new browser tab will open with a preview. ## Contributing Before contributing, you'll likely find it helpful to [understand context and general vision/direction](https://github.com/maybe-finance/maybe/wiki). -It's still very early days for this so your mileage will vary here and lots of things will break. +Once you've done that, please visit our [contributing guide](https://github.com/maybe-finance/maybe/blob/main/CONTRIBUTING.md) to get started! -But almost any contribution will be beneficial at this point. Check the [current Issues](https://github.com/maybe-finance/maybe/issues) to see where you can jump in! +## Self Hosting -If you've got an improvement, just send in a pull request! +Our long term goal is to make self-hosting as easy as possible. That said, during these early stages of building the product, we are focusing our efforts on development. -1. Fork it -2. Create your feature branch (`git checkout -b my-new-feature`) -3. Commit your changes (`git commit -am 'Add some feature'`) -4. Push to the branch (`git push origin my-new-feature`) -5. Create new Pull Request +We will update this section as we get closer to an initial release. -If you've got feature ideas, simply [open a new issue](https://github.com/maybe-finance/maybe/issues/new)! +Please see our [guide on self hosting here](https://github.com/maybe-finance/maybe/wiki/Self-Hosting-Setup-Guide). ## Repo Activity From bb1cdc1a9812802a3c78c793c0de2bf6b94a4c7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Muhammed=20K=C4=B1l=C4=B1=C3=A7?= Date: Wed, 7 Feb 2024 04:31:28 +0300 Subject: [PATCH 05/15] Update labels opacity to 75 for inactive status (#337) --- app/views/settings/edit.html.erb | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/app/views/settings/edit.html.erb b/app/views/settings/edit.html.erb index 145ec171..14a5e9d4 100644 --- a/app/views/settings/edit.html.erb +++ b/app/views/settings/edit.html.erb @@ -3,34 +3,34 @@ <%= form_with model: Current.user, url: settings_path, html: { class: "space-y-4" } do |form| %> <%= form.fields_for :family_attributes do |family_fields| %>
- <%= family_fields.label :name, "Family name", class: "block text-sm font-medium opacity-50 focus-within:opacity-100" %> + <%= family_fields.label :name, "Family name", class: "block text-sm font-medium opacity-75 focus-within:opacity-100" %> <%= family_fields.text_field :name, placeholder: "Family name", value: Current.family.name, class: "p-0 mt-1 bg-transparent border-none opacity-50 focus:outline-none focus:ring-0 focus-within:opacity-100" %>
<% end %>
- <%= form.label :first_name, class: "block text-sm font-medium opacity-50 focus-within:opacity-100" %> + <%= form.label :first_name, class: "block text-sm font-medium opacity-75 focus-within:opacity-100" %> <%= form.text_field :first_name, placeholder: "First name", value: Current.user.first_name, class: "w-full p-0 mt-1 bg-transparent border-none opacity-50 focus:outline-none focus:ring-0 focus-within:opacity-100" %>
- <%= form.label :last_name, class: "block text-sm font-medium opacity-50 focus-within:opacity-100" %> + <%= form.label :last_name, class: "block text-sm font-medium opacity-75 focus-within:opacity-100" %> <%= form.text_field :last_name, placeholder: "Last name", value: Current.user.last_name, class: "w-full p-0 mt-1 bg-transparent border-none opacity-50 focus:outline-none focus:ring-0 focus-within:opacity-100" %>
- <%= form.label :email, class: "block text-sm font-medium opacity-50 focus-within:opacity-100" %> + <%= form.label :email, class: "block text-sm font-medium opacity-75 focus-within:opacity-100" %> <%= form.email_field :email, placeholder: "Email", value: Current.user.email, class: "w-full p-0 mt-1 bg-transparent border-none opacity-50 focus:outline-none focus:ring-0 focus-within:opacity-100" %>
- <%= form.label :password, class: "block text-sm font-medium opacity-50 focus-within:opacity-100" %> + <%= form.label :password, class: "block text-sm font-medium opacity-75 focus-within:opacity-100" %> <%= form.password_field :password, class: "w-full p-0 mt-1 bg-transparent border-none opacity-50 focus:outline-none focus:ring-0 focus-within:opacity-100" %>
- <%= form.label :password_confirmation, class: "block text-sm font-medium opacity-50 focus-within:opacity-100" %> + <%= form.label :password_confirmation, class: "block text-sm font-medium opacity-75 focus-within:opacity-100" %> <%= form.password_field :password_confirmation, class: "w-full p-0 mt-1 bg-transparent border-none opacity-50 focus:outline-none focus:ring-0 focus-within:opacity-100" %>
From 2ccb52056d8b3e5687526458e9f551c94eebf58d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Muhammed=20K=C4=B1l=C4=B1=C3=A7?= Date: Wed, 7 Feb 2024 04:32:19 +0300 Subject: [PATCH 06/15] Add dotenv-rails gem to fix environment variable error for db setup (#334) * Add dotenv-rails gem to fix environment variable error for db setup * Add environment variables * Add default database values to environment variables --- .env.example | 7 ++++++- Gemfile | 1 + Gemfile.lock | 4 ++++ 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/.env.example b/.env.example index 5e08ea24..b144a286 100644 --- a/.env.example +++ b/.env.example @@ -12,4 +12,9 @@ SMTP_ADDRESS= SMTP_PORT=465 SMTP_USERNAME= SMTP_PASSWORD= -TLS=true \ No newline at end of file +TLS=true + +# Database Configuration +DB_HOST=localhost +POSTGRES_PASSWORD=postgres +POSTGRES_USER=postgres \ No newline at end of file diff --git a/Gemfile b/Gemfile index f6e21c12..87c064ed 100644 --- a/Gemfile +++ b/Gemfile @@ -34,6 +34,7 @@ group :development, :test do gem "brakeman", require: false gem "rubocop-rails-omakase", require: false gem "dotenv" + gem "dotenv-rails" gem "letter_opener" gem "i18n-tasks" end diff --git a/Gemfile.lock b/Gemfile.lock index 6efd9773..8bc62a0d 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -143,6 +143,9 @@ GEM irb (~> 1.10) reline (>= 0.3.8) dotenv (2.8.1) + dotenv-rails (2.8.1) + dotenv (= 2.8.1) + railties (>= 3.2) drb (2.2.0) ruby2_keywords erubi (1.12.0) @@ -385,6 +388,7 @@ DEPENDENCIES capybara debug dotenv + dotenv-rails hotwire-livereload i18n-tasks importmap-rails From db478e5fbd0478f3cced06d9306b100ca160f7ec Mon Sep 17 00:00:00 2001 From: Jesper Christiansen Date: Tue, 6 Feb 2024 17:45:17 -0800 Subject: [PATCH 07/15] Add Account type investment form (#343) * Add Account type investment form * Move subtypes to Account::Investment * Linting --- app/models/account/investment.rb | 12 ++++++++++++ app/views/accounts/account/_investment.html.erb | 4 ++++ 2 files changed, 16 insertions(+) diff --git a/app/models/account/investment.rb b/app/models/account/investment.rb index 57bdfcf8..87675da6 100644 --- a/app/models/account/investment.rb +++ b/app/models/account/investment.rb @@ -1,3 +1,15 @@ class Account::Investment < ApplicationRecord include Accountable + + SUBTYPES = [ + [ "Brokerage", "brokerage" ], + [ "Pension", "pension" ], + [ "Retirement", "retirement" ], + [ "401(k)", "401k" ], + [ "529 plan", "529_plan" ], + [ "Health Savings Account", "hsa" ], + [ "Mutual Fund", "mutual_fund" ], + [ "Roth IRA", "roth_ira" ], + [ "Roth 401k", "roth_401k" ] + ].freeze end diff --git a/app/views/accounts/account/_investment.html.erb b/app/views/accounts/account/_investment.html.erb index e69de29b..6310d930 100644 --- a/app/views/accounts/account/_investment.html.erb +++ b/app/views/accounts/account/_investment.html.erb @@ -0,0 +1,4 @@ +
+ + <%= f.select :subtype, options_for_select(Account::Investment::SUBTYPES, selected: ""), {}, class: "block w-full p-0 mt-1 bg-transparent border-none focus:outline-none focus:ring-0" %> +
From 6d0e5febe9ba85c3d1632c7af58b1832492a7413 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Muhammed=20K=C4=B1l=C4=B1=C3=A7?= Date: Wed, 7 Feb 2024 04:48:05 +0300 Subject: [PATCH 08/15] Fix accountable text and alignment (#330) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Fix #319 Accountable text format * Fix account index table alignment * Update to_accountable_title helper --------- Signed-off-by: Muhammed Kılıç --- app/helpers/accounts_helper.rb | 3 +++ app/views/accounts/index.html.erb | 10 +++++----- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/app/helpers/accounts_helper.rb b/app/helpers/accounts_helper.rb index 17850b4b..0673bf2a 100644 --- a/app/helpers/accounts_helper.rb +++ b/app/helpers/accounts_helper.rb @@ -1,2 +1,5 @@ module AccountsHelper + def to_accountable_title(accountable) + accountable.model_name.human + end end diff --git a/app/views/accounts/index.html.erb b/app/views/accounts/index.html.erb index ef727457..34bc5672 100644 --- a/app/views/accounts/index.html.erb +++ b/app/views/accounts/index.html.erb @@ -3,14 +3,14 @@

<%#= number_to_currency Current.family.cash_balance %>

<% Current.family.accounts.each do |account| %> -
-
+
+
<%= account.name %>
-
- <%= account.accountable.model_name.human %> +
+ <%= to_accountable_title(account.accountable) %>
-

+

<%= humanized_money_with_symbol account.balance %>

From b20867d6648c83cf68711c9cbcde3e050d230974 Mon Sep 17 00:00:00 2001 From: Cristian Livadaru Date: Wed, 7 Feb 2024 02:48:14 +0100 Subject: [PATCH 09/15] change server listening address to global (#342) listen to 0.0.0.0 instead of just local interface so it can work in Docker (and herby in devcontainers) refs #340 Credits go to @robzolkos --- Procfile.dev | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Procfile.dev b/Procfile.dev index da151fee..7410150c 100644 --- a/Procfile.dev +++ b/Procfile.dev @@ -1,2 +1,2 @@ -web: bin/rails server +web: bin/rails server -b 0.0.0.0 css: bin/rails tailwindcss:watch From 40997431072c37fb301b024cc0e3212b072ac556 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20V=C3=A1squez?= Date: Tue, 6 Feb 2024 19:51:32 -0600 Subject: [PATCH 10/15] Addd application_helper_test.rb (#302) --- test/helpers/application_helper_test.rb | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 test/helpers/application_helper_test.rb diff --git a/test/helpers/application_helper_test.rb b/test/helpers/application_helper_test.rb new file mode 100644 index 00000000..14fafe8e --- /dev/null +++ b/test/helpers/application_helper_test.rb @@ -0,0 +1,19 @@ +require "test_helper" + +class ApplicationHelperTest < ActionView::TestCase + test "#title(page_title)" do + title("Test Title") + assert_equal "Test Title", content_for(:title) + end + + test "#header_title(page_title)" do + header_title("Test Header Title") + assert_equal "Test Header Title", content_for(:header_title) + end + + test "#permitted_accountable_partial(accountable_type)" do + assert_equal "account", permitted_accountable_partial("Account") + assert_equal "user", permitted_accountable_partial("User") + assert_equal "admin_user", permitted_accountable_partial("AdminUser") + end +end From 969ee068fe71614741fcf214b2a9a4264f0bea2a Mon Sep 17 00:00:00 2001 From: Rob Zolkos Date: Wed, 7 Feb 2024 10:07:14 -0500 Subject: [PATCH 11/15] Use latest turbo-rails release (#353) This was using main branch but since 2.0 has been released this morning we can revert to that rather than pre-release versions. --- Gemfile | 2 +- Gemfile.lock | 16 +++++----------- 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/Gemfile b/Gemfile index 87c064ed..0178e748 100644 --- a/Gemfile +++ b/Gemfile @@ -20,7 +20,7 @@ gem "tailwindcss-rails" # Hotwire gem "stimulus-rails" -gem "turbo-rails", github: "hotwired/turbo-rails", branch: "main" +gem "turbo-rails" # Other gem "bcrypt", "~> 3.1.7" diff --git a/Gemfile.lock b/Gemfile.lock index 8bc62a0d..e57f3021 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,13 +1,3 @@ -GIT - remote: https://github.com/hotwired/turbo-rails.git - revision: 3748512710a29b541a1f2b3863cc6fb2422fb7e2 - branch: main - specs: - turbo-rails (2.0.0.pre.rc.2) - actionpack (>= 6.0.0) - activejob (>= 6.0.0) - railties (>= 6.0.0) - GIT remote: https://github.com/rails/rails.git revision: 554e5c2d8e8dd9f9e302a2d11c775f14c512d957 @@ -355,6 +345,10 @@ GEM unicode-display_width (>= 1.1.1, < 3) thor (1.3.0) timeout (0.4.1) + turbo-rails (2.0.0) + actionpack (>= 6.0.0) + activejob (>= 6.0.0) + railties (>= 6.0.0) tzinfo (2.0.6) concurrent-ruby (~> 1.0) unicode-display_width (2.5.0) @@ -406,7 +400,7 @@ DEPENDENCIES selenium-webdriver stimulus-rails tailwindcss-rails - turbo-rails! + turbo-rails tzinfo-data web-console From 0ebbae907a16144d47ffb87e248a42bf8bb85e23 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 7 Feb 2024 09:07:31 -0600 Subject: [PATCH 12/15] Bump rails from `554e5c2` to `f0d433b` (#349) Bumps [rails](https://github.com/rails/rails) from `554e5c2` to `f0d433b`. - [Release notes](https://github.com/rails/rails/releases) - [Commits](https://github.com/rails/rails/compare/554e5c2d8e8dd9f9e302a2d11c775f14c512d957...f0d433bb46ac233ec7fd7fae48f458978908d905) --- updated-dependencies: - dependency-name: rails dependency-type: direct:production ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index e57f3021..be1b2a68 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,6 +1,6 @@ GIT remote: https://github.com/rails/rails.git - revision: 554e5c2d8e8dd9f9e302a2d11c775f14c512d957 + revision: f0d433bb46ac233ec7fd7fae48f458978908d905 branch: main specs: actioncable (7.2.0.alpha) From 5de519945901f07a4ea39a6a7f7ba6994f8c9ae3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pedro=20L=C3=B3pez=20Mareque?= Date: Wed, 7 Feb 2024 16:09:35 +0100 Subject: [PATCH 13/15] Skip system test instead of comment it (#348) * feat: add cursor pointer in the log-in and create account pages, also make full with (it's cutted right now) the fileds in the settings edit page * feat: skip system test with an explanation instead of comment them * fix typo in the skip --- test/system/accounts_test.rb | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/test/system/accounts_test.rb b/test/system/accounts_test.rb index 030cb87d..9c4401fe 100644 --- a/test/system/accounts_test.rb +++ b/test/system/accounts_test.rb @@ -5,14 +5,16 @@ class AccountsTest < ApplicationSystemTestCase sign_in @user = users(:bob) end - # test "should create account" do - # click_on "New account" - # click_on "Credit Card" - # within "form" do - # fill_in "Name", with: "VISA" - # fill_in "Balance", with: "1000" - # click_on "Submit" - # end - # assert_text "$1,000" - # end + test "should create account" do + skip("Disabling this test for now, UI is changing to quickly to do systems testing") + + click_on "New account" + click_on "Credit Card" + within "form" do + fill_in "Name", with: "VISA" + fill_in "Balance", with: "1000" + click_on "Submit" + end + assert_text "$1,000" + end end From 88b4f2fb6bd66fbd7e0cc1264224e87277173e6f Mon Sep 17 00:00:00 2001 From: Daniel Veloso Date: Wed, 7 Feb 2024 15:22:19 +0000 Subject: [PATCH 14/15] fix: money migration (#354) --- db/migrate/20240206031739_replace_money_field.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/db/migrate/20240206031739_replace_money_field.rb b/db/migrate/20240206031739_replace_money_field.rb index dfe2b732..4c5ef9db 100644 --- a/db/migrate/20240206031739_replace_money_field.rb +++ b/db/migrate/20240206031739_replace_money_field.rb @@ -6,7 +6,7 @@ class ReplaceMoneyField < ActiveRecord::Migration[7.2] Account.reset_column_information Account.find_each do |account| - account.update_columns(balance_cents: Money.from_amount(account.balance, account.currency).cents) + account.update_columns(balance_cents: Money.from_amount(account.balance_in_database, account.currency).cents) end remove_column :accounts, :balance From 25e3ee8e4943474960a79563dfcd5e76f2d06ff2 Mon Sep 17 00:00:00 2001 From: Anthony Date: Wed, 7 Feb 2024 17:20:22 +0100 Subject: [PATCH 15/15] Remove redundant `dotenv` from `Gemfile` (#357) `dotenv` is already a `dotenv-rails` dependency so there is no need to specify it manually to the `Gemfile`. --- Gemfile | 1 - Gemfile.lock | 1 - 2 files changed, 2 deletions(-) diff --git a/Gemfile b/Gemfile index 0178e748..42d78dd4 100644 --- a/Gemfile +++ b/Gemfile @@ -33,7 +33,6 @@ group :development, :test do gem "debug", platforms: %i[ mri windows ] gem "brakeman", require: false gem "rubocop-rails-omakase", require: false - gem "dotenv" gem "dotenv-rails" gem "letter_opener" gem "i18n-tasks" diff --git a/Gemfile.lock b/Gemfile.lock index be1b2a68..e3bf36b1 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -381,7 +381,6 @@ DEPENDENCIES brakeman capybara debug - dotenv dotenv-rails hotwire-livereload i18n-tasks