@@ -55,7 +55,8 @@ class CheckoutsTest < Test::Unit::TestCase
checkout = ShopifyAPI::Checkout.find(@expected_checkout_id)
fake "checkouts/#{@expected_checkout_id}/payments", method: :get, status: 202, body: load_fixture('payments')
- assert_equal 10.00, checkout.payments.first.amount
+
+ assert_equal 10.00, checkout.payments.first.attributes['amount']
end
test ":shipping_rates returns shipping rates for a checkout" do
@@ -1,5 +1,6 @@
{
"payment" : {
+ "id": "east-44a400ef20b36e38f10b882cb7260796",
"amount": 10.00,
"session_id": "east-44a400ef20b36e38f10b882cb7260796",
"unique_token": "my-client-generated-idempotency-token"
@@ -1,9 +1,10 @@
-[
- {
- "payment" : {
+{
+ "payments" : [
+ {
}
- }
-]
+ ]
+}