$:.unshift(File.join(File.dirname(__FILE__), 'lib')) $:.unshift(File.join(File.dirname(__FILE__), 'spec')) require 'multi_json' require 'slidepay' require 'spec_helper' include SlidePay SlidePay.configure(development: true) SlidePay.api_key = ENV["api_key"] RestClient.proxy = "http://127.0.0.1:8888" # Find any payments in this company that are under review payments_found = Payment.find_where(under_review: 1) if payments_found.count > 0 puts "Payments found: #{payments_found.length}" puts "=============================================" payments_found.each do |payment| puts "#{payment.id} - #{payment["amount"]}" end else puts "No payments found to be under review. Yay(?)" end