From b50fb9034e8efd45319ce6ac3c7984bf98b548de Mon Sep 17 00:00:00 2001 From: akr Date: Sat, 7 Aug 2010 22:33:51 +0000 Subject: * ext/pathname/pathname.c (path_fnmatch): Pathname#fnmatch and Pathname#fnmatch? translated from pathname.rb. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28910 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/pathname/test_pathname.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'test/pathname') diff --git a/test/pathname/test_pathname.rb b/test/pathname/test_pathname.rb index c34d61f408..318e06b640 100644 --- a/test/pathname/test_pathname.rb +++ b/test/pathname/test_pathname.rb @@ -788,6 +788,8 @@ class TestPathname < Test::Unit::TestCase path = Pathname("a") assert_equal(true, path.fnmatch("*")) assert_equal(false, path.fnmatch("*.*")) + assert_equal(false, Pathname(".foo").fnmatch("*")) + assert_equal(true, Pathname(".foo").fnmatch("*", File::FNM_DOTMATCH)) end def test_fnmatch? -- cgit v1.2.3