mirror of
https://github.com/we-promise/sure.git
synced 2026-06-05 18:59:04 +00:00
Account namespace updates: part 5 (valuations) (#901)
* Move Valuation to Account namespace * Move account history to controller * Clean up valuation controller and views * Translations and cleanup * Remove unused scopes and methods * Pass brakeman
This commit is contained in:
@@ -44,7 +44,7 @@ class AccountsControllerTest < ActionDispatch::IntegrationTest
|
||||
end
|
||||
|
||||
test "should create an account" do
|
||||
assert_difference [ "Account.count", "Valuation.count" ], 1 do
|
||||
assert_difference [ "Account.count", "Account::Valuation.count" ], 1 do
|
||||
post accounts_path, params: {
|
||||
account: {
|
||||
accountable_type: "Depository",
|
||||
@@ -60,7 +60,7 @@ class AccountsControllerTest < ActionDispatch::IntegrationTest
|
||||
end
|
||||
|
||||
test "can add optional start date and balance to an account on create" do
|
||||
assert_difference -> { Account.count } => 1, -> { Valuation.count } => 2 do
|
||||
assert_difference -> { Account.count } => 1, -> { Account::Valuation.count } => 2 do
|
||||
post accounts_path, params: {
|
||||
account: {
|
||||
accountable_type: "Depository",
|
||||
|
||||
Reference in New Issue
Block a user