Sha256: 04279b6dc7e6840fcdbe9dfbc26ceb1177c5d33a9bba98219fe0a30f1790272a
Contents?: true
Size: 902 Bytes
Versions: 1
Compression:
Stored size: 902 Bytes
Contents
# this file is automatically required in when you require 'assert' # put test helpers here # add test dir to the load path $LOAD_PATH.unshift(File.expand_path("..", __FILE__)) class Assert::Context TMP_PATH = File.expand_path("#{File.dirname(__FILE__)}/../tmp") class << self def should_generate_name_set(name_set) name_set.variations.each do |variation| [:name, :module_name, :ruby_name].each do |name_type| should "know its :#{name_type} given '#{variation}'" do the_gem = GGem::Gem.new(TMP_PATH, variation) assert_equal name_set.send(name_type), the_gem.send(name_type) end end end end def should_create_paths(*paths) paths.flatten.each do |path| should "create the path '#{path}'" do assert File.exists?(path), "'#{path}' does not exist" end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ggem-1.1.1 | test/helper.rb |