Sha256: bbfe461da7e77718a88ed2d0f98004e84648ce434b0c806380718b66b96036f5

Contents?: true

Size: 773 Bytes

Versions: 1

Compression:

Stored size: 773 Bytes

Contents

#  _____         _
# |_   _|__  ___| |_
#   | |/ _ \/ __| __|
#   | |  __/\__ \ |_
#   |_|\___||___/\__|
#
# for lib/facets/core/dir/self/ascend.rb
#
# Extracted Tue Jul 25 10:07:15 EDT 2006
# Unit Tools Reap Test Extractor
#

require 'facets/core/dir/self/ascend.rb'


  require 'test/unit'

  class TCDir < Test::Unit::TestCase

    def test_ascend_1
      c = []
      Dir.ascend( "this/path/up" ) do |path|
        c << path
      end
      assert_equal( 'this/path/up', c[0] )
      assert_equal( 'this/path', c[1] )
      assert_equal( 'this', c[2] )
    end

    def test_ascend_2
      c = []
      Dir.ascend( "this/path/up", false ) do |path|
        c << path
      end
      assert_equal( 'this/path', c[0] )
      assert_equal( 'this', c[1] )
    end

  end


Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
facets-1.7.0 test/lib/facets/core/dir/self/test_ascend.rb