null+****@clear*****
null+****@clear*****
2012年 4月 3日 (火) 12:51:38 JST
Kouhei Sutou 2012-04-03 12:51:38 +0900 (Tue, 03 Apr 2012)
New Revision: 4b18afbb98d07d9fd06aa3776a11eef612c93087
Log:
test: grntest -> groonga_benchmark in constant and file name
Removed files:
test/unit/lib/ruby/groonga-grntest-test-utils.rb
Modified files:
test/unit/groonga-benchmark/test-gqtp.rb
test/unit/groonga-benchmark/test-http.rb
test/unit/groonga-benchmark/test-option.rb
test/unit/run-test.rb
Modified: test/unit/groonga-benchmark/test-gqtp.rb (+2 -2)
===================================================================
--- test/unit/groonga-benchmark/test-gqtp.rb 2012-04-03 12:48:16 +0900 (145ac44)
+++ test/unit/groonga-benchmark/test-gqtp.rb 2012-04-03 12:51:38 +0900 (99549c4)
@@ -15,8 +15,8 @@
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
-class GrntestGQTPTest < Test::Unit::TestCase
- include GroongaGrntestTestUtils
+class GroongaBenchmarkGQTPTest < Test::Unit::TestCase
+ include GroongaBenchmarkTestUtils
CONFIG_ENV = {"GRN_CONFIG_PATH" => ""}
Modified: test/unit/groonga-benchmark/test-http.rb (+2 -2)
===================================================================
--- test/unit/groonga-benchmark/test-http.rb 2012-04-03 12:48:16 +0900 (496c1e4)
+++ test/unit/groonga-benchmark/test-http.rb 2012-04-03 12:51:38 +0900 (bf085b5)
@@ -15,8 +15,8 @@
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
-class GrntestHTTPTest < Test::Unit::TestCase
- include GroongaGrntestTestUtils
+class GroongaBenchmarkHTTPTest < Test::Unit::TestCase
+ include GroongaBenchmarkTestUtils
CONFIG_ENV = {"GRN_CONFIG_PATH" => ""}
Modified: test/unit/groonga-benchmark/test-option.rb (+2 -2)
===================================================================
--- test/unit/groonga-benchmark/test-option.rb 2012-04-03 12:48:16 +0900 (7d84bfc)
+++ test/unit/groonga-benchmark/test-option.rb 2012-04-03 12:51:38 +0900 (8c1b68c)
@@ -15,8 +15,8 @@
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
-class GrntestOptionTest < Test::Unit::TestCase
- include GroongaGrntestTestUtils
+class GroongaBenchmarkOptionTest < Test::Unit::TestCase
+ include GroongaBenchmarkTestUtils
def setup
setup_database
Deleted: test/unit/lib/ruby/groonga-grntest-test-utils.rb (+0 -73) 100644
===================================================================
--- test/unit/lib/ruby/groonga-grntest-test-utils.rb 2012-04-03 12:48:16 +0900 (9aceb42)
+++ /dev/null
@@ -1,73 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# Copyright (C) 2010-2011 Kouhei Sutou <kou****@clear*****>
-#
-# This library is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public
-# License version 2.1 as published by the Free Software Foundation.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
-
-require "tempfile"
-require 'groonga-test-utils'
-
-module GroongaGrntestTestUtils
- include GroongaTestUtils
-
- def setup_database
- setup_database_path
- input = ""
- ["ddl.grn", "areas.grn", "categories.grn", "shops.grn"].each do |grn|
- input << File.read(taiyaki_story_fixture(grn))
- end
- output, error, status = invoke_groonga("-n", @database_path, :input => input)
- assert_predicate(status, :success?, [output, error])
- end
-
- def teardown_database
- teardown_database_path
- end
-
- private
- def guess_groonga_benchmark_path
- groonga_benchmark = ENV["GROONGA_BENCHMARK"]
- groonga_benchmark ||= File.join(guess_top_source_dir,
- "src", "groonga-benchmark")
- File.expand_path(groonga_benchmark)
- end
-
- def groonga_benchmark
- @groonga_benchmark ||= guess_groonga_benchmark_path
- end
-
- def invoke_groonga_benchmark(*args)
- args.unshift(groonga_benchmark)
- invoke_command(*args)
- end
-
- def taiyaki_story_fixture(file)
- File.join(File.dirname(__FILE__),
- "..",
- "..",
- "fixtures",
- "story",
- "taiyaki",
- file)
- end
-
- def tempfile(name)
- file = Tempfile.new(name, @tmp_base_dir)
- if block_given?
- yield(file)
- file.close
- end
- file
- end
-end
Modified: test/unit/run-test.rb (+1 -1)
===================================================================
--- test/unit/run-test.rb 2012-04-03 12:48:16 +0900 (834f314)
+++ test/unit/run-test.rb 2012-04-03 12:51:38 +0900 (45c8aad)
@@ -23,7 +23,7 @@ $LOAD_PATH.unshift(File.expand_path(File.join(base_dir, "..", "..", "tools")))
require 'groonga-test-utils'
require 'groonga-http-test-utils'
require 'groonga-local-gqtp-test-utils'
-require 'groonga-grntest-test-utils'
+require 'groonga-benchmark-test-utils'
ARGV.unshift("--exclude", "run-test.rb")
exit Test::Unit::AutoRunner.run(true, File.dirname($0))