Kouhei Sutou
null+****@clear*****
Sun Aug 17 12:11:14 JST 2014
Kouhei Sutou 2014-08-17 12:11:14 +0900 (Sun, 17 Aug 2014) New Revision: 6132e67763e05eb4468c22336d216b0c58405577 https://github.com/ranguba/rroonga/commit/6132e67763e05eb4468c22336d216b0c58405577 Message: test: ensure closing database that related with file Modified files: test/test-context.rb Modified: test/test-context.rb (+8 -4) =================================================================== --- test/test-context.rb 2014-08-17 12:05:29 +0900 (4dd1fbd) +++ test/test-context.rb 2014-08-17 12:11:14 +0900 (44472ca) @@ -199,13 +199,17 @@ COMMANDS private def restore(commands, &block) - Groonga::Database.create(:path => @database_path.to_s) - - context.restore(commands, &block) + restore_context = Groonga::Context.new + restore_context.create_database(@database_path.to_s) do + restore_context.restore(commands, &block) + end end def dump - Groonga::DatabaseDumper.dump + dump_context = Groonga::Context.new + dump_context.open_database(@database_path.to_s) do + Groonga::DatabaseDumper.dump(:context => dump_context) + end end end end -------------- next part -------------- HTML����������������������������... Télécharger