1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* test/gdbm/test_gdbm.rb (TestGDBM2#test_writer_open_notexist):

gdbm 1.8.x changed GDBM::WRITER behavior. Thus our testcase need
	  to be changed too.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30707 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
kosaki 2011-01-28 08:50:18 +00:00
parent 36f71db31e
commit 3a0ec68109
2 changed files with 18 additions and 3 deletions

View file

@ -1,3 +1,9 @@
Fri Jan 28 17:47:33 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
* test/gdbm/test_gdbm.rb (TestGDBM2#test_writer_open_notexist):
gdbm 1.8.x changed GDBM::WRITER behavior. Thus our testcase need
to be changed too.
Fri Jan 28 17:33:28 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com> Fri Jan 28 17:33:28 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
* test/gdbm/test_gdbm.rb (TestGDBM#test_s_open_no_create): skip * test/gdbm/test_gdbm.rb (TestGDBM#test_s_open_no_create): skip

View file

@ -667,9 +667,18 @@ if defined? GDBM
end end
def test_writer_open_notexist def test_writer_open_notexist
assert_raise(Errno::ENOENT) { if /1\.8\./ =~ GDBM::VERSION
GDBM.open("#{@tmproot}/a", 0666, GDBM::WRITER) # 1.8.x are using O_RDWR|O_CREAT.
} assert_nothing_raised {
GDBM.open("#{@tmproot}/a", 0666, GDBM::WRITER)
}
else
# 1.7.x are using O_RDWR.
assert_raise(Errno::ENOENT) {
GDBM.open("#{@tmproot}/a", 0666, GDBM::WRITER)
}
end
end end
def test_wrcreat_open_notexist def test_wrcreat_open_notexist