Sha256: e203ab16a8c07f00a8e3a2ea88da43d81e313bbe99ccc0b44d13c54d0c14a1dc

Contents?: true

Size: 461 Bytes

Versions: 4

Compression:

Stored size: 461 Bytes

Contents

require 'helper'
require 'peddler/errors/error'

class TestPeddlerErrorsError < MiniTest::Test
  def setup
    @error = Peddler::Errors::Error.new('message', 'cause')
  end

  def test_sets_message
    assert_equal 'message', @error.message
  end

  def test_sets_cause
    assert_equal 'cause', @error.cause
  end

  def test_defines_common_errors
    Peddler::Errors::CODES.each do |name|
      assert ::Peddler::Errors.const_defined?(name)
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
peddler-1.6.3 test/unit/peddler/errors/test_error.rb
peddler-1.6.2 test/unit/peddler/errors/test_error.rb
peddler-1.6.1 test/unit/peddler/errors/test_error.rb
peddler-1.6.0 test/unit/peddler/errors/test_error.rb