mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-07-20 05:39:39 +02:00
20 lines
476 B
Ruby
20 lines
476 B
Ruby
|
require "test_helper"
|
||
|
|
||
|
class ValuationsControllerTest < ActionDispatch::IntegrationTest
|
||
|
setup do
|
||
|
sign_in @user = users(:bob)
|
||
|
@account = accounts(:dylan_checking)
|
||
|
end
|
||
|
|
||
|
test "new" do
|
||
|
get new_account_valuation_url(@account)
|
||
|
assert_response :success
|
||
|
end
|
||
|
|
||
|
test "create" do
|
||
|
assert_difference("Valuation.count") do
|
||
|
post account_valuations_url(@account), params: { valuation: { value: 1, date: Date.current, type: "Appraisal" } }
|
||
|
end
|
||
|
end
|
||
|
end
|