Sha256: 2c40fb71b3c15f75c9769f092047ff71b6662c0d9ee2e87dedfe2a9a75c2c59d
Contents?: true
Size: 1.17 KB
Versions: 22
Compression:
Stored size: 1.17 KB
Contents
require 'test_helper' class EpsilonConvenienceStoreTest < MiniTest::Test def test_blank_parameter_generate_error convenience_store = ActiveMerchant::Billing::ConvenienceStore.new(code: "", full_name_kana: "", phone_number: "") errors = convenience_store.validate assert_includes errors.keys, :code assert_includes errors.keys, :full_name_kana assert_includes errors.keys, :phone_number assert_includes errors[:code], "is required" assert_includes errors[:full_name_kana], "is required" assert_includes errors[:phone_number], "is required" end def test_phone_number_only_accept_number convenience_store = ActiveMerchant::Billing::ConvenienceStore.new(code: 31, full_name_kana: "ใในใ", phone_number: "test") errors = convenience_store.validate assert_includes errors.keys, :phone_number assert_includes errors[:phone_number], "is not number" end end
Version data entries
22 entries across 22 versions & 1 rubygems
Version | Path |
---|---|
active_merchant-epsilon-0.5.5 | test/unit/billing/convenience_store_test.rb |
active_merchant-epsilon-0.5.4 | test/unit/billing/convenience_store_test.rb |