Sha256: 8c22c9865a8040fb38a0debcf1cd930fd0f0ead33e90b11062eb17e9582ac8c7
Contents?: true
Size: 597 Bytes
Versions: 10
Compression:
Stored size: 597 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
10 entries across 10 versions & 1 rubygems