~singpolyma/sgx-jmp

ref: 023c87a11bbaa6bd3eaeb3977330b8ea80ded0cd sgx-jmp/test/test_plan.rb -rw-r--r-- 489 bytes
023c87a1Stephen Paul Weber Quieter voicemail beep 1 year, 10 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# frozen_string_literal: true

require "test_helper"
require "plan"

class PlanTest < Minitest::Test
	def test_for_non_existing
		assert_raises do
			Plan.for("non_existing")
		end
	end

	def test_currency
		assert_equal :USD, Plan.for("test_usd").currency
	end

	def test_merchant_account
		assert_equal "merchant_usd", Plan.for("test_usd").merchant_account
	end

	def test_merchant_account_bad_currency
		assert_raises do
			Plan.for("test_bad_currency").merchant_account
		end
	end
end