1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-12-01 12:24:28 +01:00
fab-manager/test/models/wallet_transaction_test.rb

14 lines
404 B
Ruby

require 'test_helper'
class WalletTransactionTest < ActiveSupport::TestCase
test 'transaction type must be credit or debit' do
transaction = WalletTransaction.new
transaction.transaction_type = 'credit'
assert transaction.valid?
transaction.transaction_type = 'debit'
assert transaction.valid?
transaction.transaction_type = 'other'
assert_not transaction.valid?
end
end