           results.Cart.should.have.property 'CartId'
           results.Cart.should.have.property 'HMAC'
           results.Cart.CartItems.CartItem.should.be.an.Array
+          cartId = results.Cart.CartId
+          cartHMAC = results.Cart.HMAC
 
     describe 'when callback is passed', ->
       it 'should return results from amazon', (done)->

            results.Cart.should.have.property 'CartId'
            results.Cart.should.have.property 'HMAC'
            results.Cart.CartItems.CartItem.should.be.an.Array
            done()

  describe 'when credentials are invalid', ->

          err.Cart.Request.should.have.property 'Errors'
          err.Cart.Request.Errors.should.be.an.Array
          done()

describe 'client.cartClear(query, cb)', ->
  cartId = ''
  cartHMAC = ''

  before (done) ->
    client = amazonAffiliateApi.createClient credentials
    client.cartCreate
      items: [
        {
          ASIN: 'B00LZTHUH6'
          Quantity: 1
        }
      ]
    .then (results) ->
      cartId = results.Cart.CartId
      cartHMAC = results.Cart.HMAC
      done()

  describe 'when credentials are valid', ->
    client = amazonAffiliateApi.createClient credentials
