Kouhei Sutou
null+****@clear*****
Mon Jun 6 16:28:33 JST 2016
Kouhei Sutou 2016-06-06 16:28:33 +0900 (Mon, 06 Jun 2016) New Revision: d6a385ad43db6f290cc978f0aeb9306a9a443ac5 https://github.com/ranguba/rroonga/commit/d6a385ad43db6f290cc978f0aeb9306a9a443ac5 Message: Add Groonga::ProcedureType::WINDOW_FUNCTION Modified files: ext/groonga/rb-grn-procedure-type.c test/test-procedure.rb Modified: ext/groonga/rb-grn-procedure-type.c (+9 -1) =================================================================== --- ext/groonga/rb-grn-procedure-type.c 2016-06-06 16:02:45 +0900 (b0ea94b) +++ ext/groonga/rb-grn-procedure-type.c 2016-06-06 16:28:33 +0900 (7fe4aff) @@ -1,6 +1,6 @@ /* -*- coding: utf-8; mode: C; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /* - Copyright (C) 2014 Kouhei Sutou <kou �� clear-code.com> + Copyright (C) 2014-2016 Kouhei Sutou <kou �� clear-code.com> This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public @@ -41,4 +41,12 @@ rb_grn_init_procedure_type (VALUE mGrn) "TOKEN_FILTER", INT2NUM(GRN_PROC_TOKEN_FILTER)); rb_define_const(rb_mGrnProcedureType, "SCORER", INT2NUM(GRN_PROC_SCORER)); + + /* + * It's a type for window function. + * + * @since 6.0.4 + */ + rb_define_const(rb_mGrnProcedureType, + "WINDOW_FUNCTION", INT2NUM(GRN_PROC_WINDOW_FUNCTION)); } Modified: test/test-procedure.rb (+6 -0) =================================================================== --- test/test-procedure.rb 2016-06-06 16:02:45 +0900 (712f093) +++ test/test-procedure.rb 2016-06-06 16:28:33 +0900 (c05d8d2) @@ -70,6 +70,12 @@ class ProcedureTest < Test::Unit::TestCase scorer = Groonga["scorer_tf_idf"] assert_equal(Groonga::ProcedureType::SCORER, scorer.type) end + + def test_window_function + record_number = Groonga["record_number"] + assert_equal(Groonga::ProcedureType::WINDOW_FUNCTION, + record_number.type) + end end class SelectorOnlyProcedureTest < self -------------- next part -------------- HTML����������������������������... 下載