paypal-checkout-sdk 1.0.1 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. checksums.yaml +5 -5
  2. data/.gitignore +139 -0
  3. data/Gemfile +3 -0
  4. data/Gemfile.lock +48 -0
  5. data/LICENSE +86 -0
  6. data/README.md +142 -0
  7. data/Rakefile +6 -0
  8. data/gen.yml +6 -0
  9. data/homepage.jpg +0 -0
  10. data/init +0 -0
  11. data/lib/core/version.rb +1 -1
  12. data/paypal-checkout-sdk.gemspec +26 -12
  13. data/samples/authorize_intent_examples/authorize_order.rb +52 -0
  14. data/samples/authorize_intent_examples/capture_order.rb +44 -0
  15. data/samples/authorize_intent_examples/create_order.rb +191 -0
  16. data/samples/authorize_intent_examples/run_all.rb +57 -0
  17. data/samples/capture_intent_examples/capture_order.rb +50 -0
  18. data/samples/capture_intent_examples/create_order.rb +138 -0
  19. data/samples/capture_intent_examples/run_all.rb +58 -0
  20. data/samples/get_order.rb +43 -0
  21. data/samples/patch_order.rb +53 -0
  22. data/samples/paypal_client.rb +40 -0
  23. data/samples/refund_capture.rb +46 -0
  24. metadata +82 -22
  25. data/spec/orders/orders_authorize_spec.rb +0 -18
  26. data/spec/orders/orders_capture_spec.rb +0 -18
  27. data/spec/orders/orders_create_spec.rb +0 -36
  28. data/spec/orders/orders_get_spec.rb +0 -37
  29. data/spec/orders/orders_helper.rb +0 -33
  30. data/spec/orders/orders_patch_spec.rb +0 -60
  31. data/spec/orders/orders_validate_spec.rb +0 -18
  32. data/spec/payments/authorizations_capture_spec.rb +0 -18
  33. data/spec/payments/authorizations_get_spec.rb +0 -18
  34. data/spec/payments/authorizations_reauthorize_spec.rb +0 -17
  35. data/spec/payments/authorizations_void_spec.rb +0 -17
  36. data/spec/payments/captures_get_spec.rb +0 -18
  37. data/spec/payments/captures_refund_spec.rb +0 -18
  38. data/spec/payments/refunds_get_spec.rb +0 -18
  39. data/spec/spec_helper.rb +0 -109
  40. data/spec/test_harness.rb +0 -25
data/spec/test_harness.rb DELETED
@@ -1,25 +0,0 @@
1
- require 'braintreehttp'
2
- require './lib/paypal-checkout-sdk'
3
-
4
- module TestHarness
5
- class << self
6
- def environment
7
- client_id = ENV['PAYPAL_CLIENT_ID'] || '<<PAYPAL-CLIENT-ID>>'
8
- client_secret = ENV['PAYPAL_CLIENT_SECRET'] || '<<PAYPAL-CLIENT-SECRET>>'
9
-
10
- PayPal::SandboxEnvironment.new(client_id, client_secret)
11
- end
12
-
13
- def client
14
- PayPal::PayPalHttpClient.new(self.environment)
15
- end
16
-
17
- def exec(req, body = nil)
18
- if body
19
- req.request_body(body)
20
- end
21
-
22
- client.execute(req)
23
- end
24
- end
25
- end