Sha256: f7dea01a7516d91197930145fcb6d54d0e2920ae524c381c767763e15eef16f6
Contents?: true
Size: 805 Bytes
Versions: 5
Compression:
Stored size: 805 Bytes
Contents
# Copyright (c) 2009 Michael Fellinger m.fellinger@gmail.com # All files in this distribution are subject to the terms of the MIT license. require File.expand_path('../../../../lib/ramaze/spec/helper/snippets', __FILE__) describe '__DIR__' do # this is hardly exhaustive, but better than nothing it 'should report the directory of the current file' do __DIR__.should == File.dirname(File.expand_path(__FILE__)) end should 'join passed arguments and prefix with directory of current file' do __DIR__(:foo).should == File.join(File.dirname(File.expand_path(__FILE__)), 'foo') __DIR__('foo/bar').should == File.join(File.dirname(File.expand_path(__FILE__)), 'foo/bar') __DIR__(:foo, :bar).should == File.join(File.dirname(File.expand_path(__FILE__)), 'foo/bar') end end
Version data entries
5 entries across 5 versions & 1 rubygems