spec/integration/braintree/credit_card_spec.rb in braintree-4.19.0 vs spec/integration/braintree/credit_card_spec.rb in braintree-4.20.0
- old
+ new
@@ -705,10 +705,12 @@
)
end.to raise_error(Braintree::ValidationsFailed)
end
end
+ # NEXT_MAJOR_VERSION remove this test
+ # CreditCard.credit has been deprecated in favor of Transaction.credit
describe "self.credit" do
it "creates a credit transaction using the payment method token, returning a result object" do
customer = Braintree::Customer.create!(
:credit_card => {
:number => Braintree::Test::CreditCardNumbers::Visa,
@@ -1336,10 +1338,12 @@
Braintree::CreditCard.from_nonce(nonce)
end.to raise_error(Braintree::NotFoundError, /consumed/)
end
end
+ # NEXT_MAJOR_VERSION remove these tests
+ # CreditCard.sale has been deprecated in favor of Transaction.sale
describe "self.sale" do
it "creates a sale transaction using the credit card, returning a result object" do
customer = Braintree::Customer.create!(
:credit_card => {
:number => Braintree::Test::CreditCardNumbers::Visa,
@@ -1379,9 +1383,11 @@
expect(result.transaction.credit_card_details.token).to eq(customer.credit_cards[0].token)
expect(result.transaction.cvv_response_code).to eq("S")
end
end
+ # NEXT_MAJOR_VERSION remove this test
+ # CreditCard.sale has been deprecated in favor of Transaction.sale
describe "self.sale!" do
it "creates a sale transaction using the credit card, returning the transaction" do
customer = Braintree::Customer.create!(
:credit_card => {
:number => Braintree::Test::CreditCardNumbers::Visa,