mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-07-24 07:39:39 +02:00
Add loan and credit card views (#1268)
* Add loan and credit card views * Lint fix * Clean up overview card markup * Lint fix * Test fix
This commit is contained in:
parent
9263dd3bbe
commit
fd941d714d
34 changed files with 564 additions and 102 deletions
|
@ -22,13 +22,13 @@ class AccountsTest < ApplicationSystemTestCase
|
|||
|
||||
test "can create property account" do
|
||||
assert_account_created "Property" do
|
||||
fill_in "Year built (optional)", with: 2005
|
||||
fill_in "Area value (optional)", with: 2250
|
||||
fill_in "Year built", with: 2005
|
||||
fill_in "Area value", with: 2250
|
||||
fill_in "Address line 1", with: "123 Main St"
|
||||
fill_in "Address line 2", with: "Apt 4B"
|
||||
fill_in "City", with: "San Francisco"
|
||||
fill_in "State", with: "CA"
|
||||
fill_in "Postal code (optional)", with: "94101"
|
||||
fill_in "Postal code", with: "94101"
|
||||
fill_in "Country", with: "US"
|
||||
end
|
||||
end
|
||||
|
@ -47,11 +47,21 @@ class AccountsTest < ApplicationSystemTestCase
|
|||
end
|
||||
|
||||
test "can create credit card account" do
|
||||
assert_account_created("CreditCard")
|
||||
assert_account_created "CreditCard" do
|
||||
fill_in "Available credit", with: 1000
|
||||
fill_in "Minimum payment", with: 25
|
||||
fill_in "APR", with: 15.25
|
||||
fill_in "Expiration date", with: 1.year.from_now.to_date
|
||||
fill_in "Annual fee", with: 100
|
||||
end
|
||||
end
|
||||
|
||||
test "can create loan account" do
|
||||
assert_account_created("Loan")
|
||||
assert_account_created "Loan" do
|
||||
fill_in "Interest rate", with: 5.25
|
||||
select "Fixed", from: "Rate type"
|
||||
fill_in "Term (months)", with: 360
|
||||
end
|
||||
end
|
||||
|
||||
test "can create other liability account" do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue