Sha256: 2fedcd85af1a77abeb8a247bb85edb34cf685d04eeee070a41fc0c5bcf7d7430
Contents?: true
Size: 596 Bytes
Versions: 19
Compression:
Stored size: 596 Bytes
Contents
# frozen_string_literal: true require 'rubygems/test_case' class TestGemSourceFetchProblem < Gem::TestCase def test_exception source = Gem::Source.new @gem_repo error = RuntimeError.new 'test' sf = Gem::SourceFetchProblem.new source, error e = assert_raises RuntimeError do raise sf end assert_equal 'test', e.message end def test_password_redacted source = Gem::Source.new 'https://username:secret@gemsource.com' error = RuntimeError.new 'test' sf = Gem::SourceFetchProblem.new source, error refute_match sf.wordy, 'secret' end end
Version data entries
19 entries across 19 versions & 1 rubygems