Sha256: 8b7da841839fc81a761209f0e880a82fc03bbc2d956186eca8de3524211cb1b2

Contents?: true

Size: 371 Bytes

Versions: 1

Compression:

Stored size: 371 Bytes

Contents

require "spec_helper"

module Bickle
  describe ResponseParser do
    it "returns JSON when given valid input" do
      result = ResponseParser.parse("{\"a\": 123}")
      result.should == {"a" => 123}
    end

    it "returns error on invalid input" do
      expect do
        ResponseParser.parse("foo")
      end.to raise_error(InvalidResponseError)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bickle-0.0.1 spec/response_parser_spec.rb