comment out payment check verification

This commit is contained in:
olegphenomenon 2023-05-05 13:22:33 +03:00
parent 504e817374
commit fecc3061c8
2 changed files with 1 additions and 7 deletions

View file

@ -12,7 +12,7 @@ class PaymentOrder < ApplicationRecord
belongs_to :invoice, optional: false
validate :invoice_cannot_be_already_paid, on: :create
validate :supported_payment_method
# validate :supported_payment_method
enum status: { issued: 'issued', paid: 'paid', cancelled: 'cancelled',
failed: 'failed' }

View file

@ -76,12 +76,6 @@ class PaymentOrdersTest < ActiveSupport::TestCase
assert_includes payment_order.errors[:invoice], 'is already paid'
end
def test_order_without_channel_is_invalid
payment_order = PaymentOrder.new
assert payment_order.invalid?
assert_includes payment_order.errors[:type], 'is not supported'
end
def test_can_not_create_order_with_invalid_type
assert_raise NameError do
PaymentOrder.new_with_type(type: 'not_implemented', invoice: Invoice.new)