Sha256: 95fa71209544bbed33c00056dc004068c55f412b059dd7844f97c274d34e04b7

Contents?: true

Size: 597 Bytes

Versions: 17

Compression:

Stored size: 597 Bytes

Contents

# frozen_string_literal: true
require 'rubygems/test_case'
require 'rubygems'

class TestConfig < Gem::TestCase

  def test_datadir
    util_make_gems
    spec = Gem::Specification.find_by_name("a")
    spec.activate
    assert_equal "#{spec.full_gem_path}/data/a", Gem.datadir('a')
  end

  def test_good_rake_path_is_escaped
    path = Gem::TestCase.class_eval('@@good_rake')
    assert_match(/#{Gem.ruby} "[^"]*good_rake.rb"/, path)
  end

  def test_bad_rake_path_is_escaped
    path = Gem::TestCase.class_eval('@@bad_rake')
    assert_match(/#{Gem.ruby} "[^"]*bad_rake.rb"/, path)
  end

end

Version data entries

17 entries across 17 versions & 2 rubygems

Version Path
rubygems-update-2.6.14 test/rubygems/test_config.rb
rubygems-update-2.6.13 test/rubygems/test_config.rb
rubygems-update-2.6.12 test/rubygems/test_config.rb
rubygems-update-2.6.11 test/rubygems/test_config.rb
rubygems-update-2.6.10 test/rubygems/test_config.rb
rubygems-update-2.6.9 test/rubygems/test_config.rb
ruby-compiler-0.1.1 vendor/ruby/test/rubygems/test_config.rb
rubygems-update-2.6.8 test/rubygems/test_config.rb
rubygems-update-2.6.7 test/rubygems/test_config.rb
rubygems-update-2.6.6 test/rubygems/test_config.rb
rubygems-update-2.6.5 test/rubygems/test_config.rb
rubygems-update-2.6.4 test/rubygems/test_config.rb
rubygems-update-2.6.3 test/rubygems/test_config.rb
rubygems-update-2.6.2 test/rubygems/test_config.rb
rubygems-update-2.6.1 test/rubygems/test_config.rb
rubygems-update-2.6.0 test/rubygems/test_config.rb
rubygems-update-2.5.2 test/rubygems/test_config.rb