Add some model tests (#9)
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
Reviewed-on: #9
This commit is contained in:
parent
dd881ee41c
commit
e1a7f4fbbd
11 changed files with 113 additions and 37 deletions
|
@ -1,7 +1,27 @@
|
|||
require "test_helper"
|
||||
|
||||
class MemberTest < ActiveSupport::TestCase
|
||||
# test "the truth" do
|
||||
# assert true
|
||||
# end
|
||||
def member
|
||||
members(:one)
|
||||
end
|
||||
|
||||
def test_income
|
||||
assert_equal 110_000.00, member.income
|
||||
end
|
||||
|
||||
def test_included_income
|
||||
assert_equal 100_000.00, member.included_income
|
||||
end
|
||||
|
||||
def test_others_included_income
|
||||
assert_equal 10_000.00, member.others_included_income
|
||||
end
|
||||
|
||||
def test_burden_percent
|
||||
assert_equal 0.91, member.burden_percent
|
||||
end
|
||||
|
||||
def test_burden_amount
|
||||
assert_equal 627.90, member.burden_amount
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue