Sha256: e5b739a9fc909dc3a443abdbcc95a40c8e05c094a8db1d7bb6435aff146d5b72
Contents?: true
Size: 464 Bytes
Versions: 1
Compression:
Stored size: 464 Bytes
Contents
require "unit_spec_helper" describe Rpush::TooManyRequestsError do let(:response) { double(code: 429, header: { 'retry-after' => 3600 }) } let(:error) { Rpush::TooManyRequestsError.new(429, 12, "Too Many Requests", response) } it "returns an informative message" do error.to_s.should eq "Too many requests for 12, received error 429 (Too Many Requests) - retry after 3600" end it "returns the error code" do error.code.should eq 429 end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
rpush-2.0.0.beta1 | spec/unit/daemon/too_many_requests_error_spec.rb |