Sha256: 50c301dccaf768689e9ca1ea47d84915d75a754b3e4ac4f6695a03302324e3cc
Contents?: true
Size: 801 Bytes
Versions: 6
Compression:
Stored size: 801 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + '/helper') class TestDependencies < Test::Unit::TestCase context 'when we require a dependency that have another dependecy' do should 'raise an error without padrino' do assert_raise NameError do require "fixtures/dependencies/a.rb" require "fixtures/dependencies/b.rb" require "fixtures/dependencies/c.rb" end end should 'resolve dependency problems' do silence_warnings do Padrino.require_dependencies( Padrino.root("fixtures/dependencies/a.rb"), Padrino.root("fixtures/dependencies/b.rb"), Padrino.root("fixtures/dependencies/c.rb") ) end assert_equal ["B", "A"], A_result assert_equal ["C", "B"], B_result end end end
Version data entries
6 entries across 6 versions & 1 rubygems