Sha256: 8a6d3d4cd1487c73e5b70f041647e058ea22f267bb459b991a5c8abc2cec8dda

Contents?: true

Size: 539 Bytes

Versions: 13

Compression:

Stored size: 539 Bytes

Contents

require 'rest-core'

require 'rr'
require 'webmock'
require 'bacon'

# for testing lighten (serialization)
require 'yaml'

include RR::Adapters::RRMethods
include WebMock::API
WebMock.disable_net_connect!
Bacon.summary_on_exit

module TestHelper
  module_function
  def normalize_query query
    '?' + query[1..-1].split('&').sort.join('&')
  end

  def normalize_url url
    url.sub(/\?.+/){ |query| TestHelper.normalize_query(query) }
  end
end

module Kernel
  def eq? rhs
    self == rhs
  end

  def lt? rhs
    self < rhs
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
rest-core-1.0.3 lib/rest-core/test.rb
rest-core-1.0.2 lib/rest-core/test.rb
rest-core-1.0.1 lib/rest-core/test.rb
rest-core-1.0.0 lib/rest-core/test.rb
rest-core-0.8.2 lib/rest-core/test.rb
rest-core-0.8.1 lib/rest-core/test.rb
rest-core-0.8.0 lib/rest-core/test.rb
rest-core-0.7.2 lib/rest-core/test.rb
rest-core-0.7.0 lib/rest-core/test.rb
rest-core-0.4.0 lib/rest-core/test.rb
rest-core-0.4.0.pre.2 lib/rest-core/test.rb
rest-core-0.4.0.pre.1 lib/rest-core/test.rb
rest-core-0.4.0.pre.0 lib/rest-core/test.rb