rroonga 9.0.3 → 9.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -395,6 +395,19 @@ column_create Terms Items_title COLUMN_INDEX|WITH_POSITION|INDEX_MEDIUM Items ti
395
395
  SCHEMA
396
396
  end
397
397
 
398
+ def test_large_index
399
+ define_index_schema(:title_index_options => {:size => :large})
400
+ assert_equal(<<-SCHEMA, dump)
401
+ table_create Items TABLE_HASH_KEY ShortText
402
+ column_create Items title COLUMN_SCALAR ShortText
403
+
404
+ table_create Terms TABLE_PAT_KEY ShortText --default_tokenizer TokenBigram --token_filters TokenFilterStopWord --normalizer NormalizerAuto
405
+
406
+ column_create Terms Items__key COLUMN_INDEX|WITH_POSITION Items _key
407
+ column_create Terms Items_title COLUMN_INDEX|WITH_POSITION|INDEX_LARGE Items title
408
+ SCHEMA
409
+ end
410
+
398
411
  def test_weight_vector
399
412
  define_weight_vector_schema
400
413
  assert_equal(<<-SCHEMA, dump)
@@ -1,4 +1,4 @@
1
- # Copyright (C) 2009-2013 Kouhei Sutou <kou@clear-code.com>
1
+ # Copyright (C) 2009-2019 Kouhei Sutou <kou@clear-code.com>
2
2
  # Copyright (C) 2016 Masafumi Yokoyama <yokoyama@clear-code.com>
3
3
  #
4
4
  # This library is free software; you can redistribute it and/or
@@ -276,6 +276,25 @@ class TableTest < Test::Unit::TestCase
276
276
  bookmark["created_at"].to_a)
277
277
  end
278
278
 
279
+ sub_test_case "#support_score?" do
280
+ setup
281
+ def setup_table
282
+ @table = Groonga::Hash.create(:name => "Bookmarks")
283
+ end
284
+
285
+ test "true" do
286
+ assert do
287
+ @table.select.support_score?
288
+ end
289
+ end
290
+
291
+ test "false" do
292
+ assert do
293
+ not @table.support_score?
294
+ end
295
+ end
296
+ end
297
+
279
298
  class DeleteTest < self
280
299
  setup
281
300
  def setup_data
@@ -738,6 +757,7 @@ class TableTest < Test::Unit::TestCase
738
757
 
739
758
  private
740
759
  def by_other_process
760
+ only_not_windows
741
761
  pid = Process.fork do
742
762
  yield
743
763
  end
@@ -1,4 +1,4 @@
1
- # Copyright (C) 2009 Kouhei Sutou <kou@clear-code.com>
1
+ # Copyright (C) 2009-2019 Sutou Kouhei <kou@clear-code.com>
2
2
  #
3
3
  # This library is free software; you can redistribute it and/or
4
4
  # modify it under the terms of the GNU Lesser General Public
@@ -16,13 +16,29 @@
16
16
  class VariableTest < Test::Unit::TestCase
17
17
  include GroongaTestUtils
18
18
 
19
- setup :setup_database
19
+ def setup
20
+ setup_database
21
+ @expression = Groonga::Expression.new
22
+ @variable = @expression.define_variable
23
+ end
20
24
 
21
25
  def test_value
22
- expression = Groonga::Expression.new
23
- variable = expression.define_variable
24
- assert_nil(variable.value)
25
- variable.value = "morita"
26
- assert_equal("morita", variable.value)
26
+ assert_nil(@variable.value)
27
+ @variable.value = "morita"
28
+ assert_equal("morita", @variable.value)
29
+ end
30
+
31
+ sub_test_case("#bulk?") do
32
+ def test_true
33
+ assert do
34
+ @variable.bulk?
35
+ end
36
+ end
37
+
38
+ def test_false
39
+ assert do
40
+ not @expression.bulk?
41
+ end
42
+ end
27
43
  end
28
44
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rroonga
3
3
  version: !ruby/object:Gem::Version
4
- version: 9.0.3
4
+ version: 9.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kouhei Sutou
@@ -12,7 +12,7 @@ authors:
12
12
  autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
- date: 2019-05-10 00:00:00.000000000 Z
15
+ date: 2019-08-29 00:00:00.000000000 Z
16
16
  dependencies:
17
17
  - !ruby/object:Gem::Dependency
18
18
  name: pkg-config
@@ -194,10 +194,10 @@ email:
194
194
  - y.hayamizu@gmail.com
195
195
  - dara@shidara.net
196
196
  executables:
197
- - grntest-log-analyze
197
+ - grndump
198
198
  - groonga-database-inspect
199
+ - grntest-log-analyze
199
200
  - groonga-index-dump
200
- - grndump
201
201
  extensions:
202
202
  - ext/groonga/extconf.rb
203
203
  extra_rdoc_files:
@@ -419,73 +419,73 @@ specification_version: 4
419
419
  summary: Ruby bindings for Groonga that provide full text search and column store
420
420
  features.
421
421
  test_files:
422
- - test/test-double-array-trie.rb
423
- - test/test-error-message.rb
424
- - test/test-token-regexp.rb
425
- - test/test-encoding.rb
426
- - test/test-context.rb
427
- - test/test-schema-dumper.rb
422
+ - test/test-column-cache.rb
423
+ - test/test-remote.rb
424
+ - test/run-test.rb
425
+ - test/test-query-logger.rb
428
426
  - test/test-data-column.rb
427
+ - test/test-database-inspector.rb
428
+ - test/test-type.rb
429
+ - test/test-column.rb
430
+ - test/test-expression.rb
431
+ - test/test-fix-size-column.rb
432
+ - test/test-table-offset-and-limit.rb
433
+ - test/test-windows-event-logger.rb
429
434
  - test/test-lock-timeout.rb
430
435
  - test/test-convert.rb
431
- - test/test-memory-pool.rb
436
+ - test/test-accessor.rb
437
+ - test/test-context.rb
438
+ - test/test-procedure.rb
439
+ - test/test-table-traverse.rb
440
+ - test/test-sub-records.rb
441
+ - test/test-package-label.rb
442
+ - test/test-logger.rb
443
+ - test/test-table-select.rb
444
+ - test/test-config.rb
445
+ - test/test-table-select-weight.rb
446
+ - test/test-flushable.rb
447
+ - test/test-token-regexp.rb
448
+ - test/test-variable.rb
449
+ - test/test-thread.rb
450
+ - test/test-index-cursor.rb
451
+ - test/test-table.rb
452
+ - test/test-operator.rb
453
+ - test/test-default-cache.rb
454
+ - test/test-error-message.rb
455
+ - test/test-vector-column.rb
432
456
  - test/test-index-column.rb
433
457
  - test/test-exception.rb
434
- - test/test-table.rb
435
- - test/run-test.rb
436
- - test/test-flushable.rb
437
- - test/test-variable-size-column.rb
438
- - test/test-table-select-mecab.rb
439
- - test/test-remote.rb
458
+ - test/test-expression-builder.rb
459
+ - test/test-double-array-trie.rb
460
+ - test/test-plugin.rb
461
+ - test/test-table-group.rb
462
+ - test/test-snippet.rb
463
+ - test/test-schema-dumper.rb
464
+ - test/test-table-dumper.rb
465
+ - test/test-gqtp.rb
466
+ - test/test-memory-pool.rb
440
467
  - test/test-array.rb
441
- - test/test-table-select-normalize.rb
468
+ - test/groonga-test-utils.rb
442
469
  - test/test-geo-point.rb
443
- - test/test-logger.rb
444
- - test/test-expression.rb
445
- - test/test-procedure.rb
446
- - test/test-fix-size-column.rb
447
- - test/test-id.rb
448
- - test/test-windows-event-logger.rb
470
+ - test/test-table-select-mecab.rb
471
+ - test/test-normalizer.rb
472
+ - test/test-pagination.rb
449
473
  - test/test-schema-type.rb
450
- - test/test-table-select-weight.rb
451
- - test/test-accessor.rb
452
- - test/test-type.rb
453
- - test/test-hash.rb
454
474
  - test/test-patricia-trie.rb
455
- - test/test-query-logger.rb
456
- - test/test-record.rb
457
- - test/test-column.rb
458
- - test/test-vector-column.rb
459
- - test/test-variable.rb
460
- - test/test-table-group.rb
461
- - test/test-table-offset-and-limit.rb
462
- - test/test-default-cache.rb
463
- - test/test-normalizer.rb
464
- - test/test-table-key-support.rb
475
+ - test/test-table-select-normalize.rb
476
+ - test/test-version.rb
477
+ - test/test-hash.rb
478
+ - test/test-encoding.rb
465
479
  - test/test-name.rb
480
+ - test/test-table-arrow.rb
481
+ - test/test-variable-size-column.rb
466
482
  - test/test-database.rb
467
- - test/test-version.rb
468
- - test/test-pagination.rb
469
- - test/test-database-inspector.rb
470
- - test/test-sub-records.rb
471
- - test/test-gqtp.rb
483
+ - test/test-command-select.rb
484
+ - test/test-record.rb
485
+ - test/test-table-key-support.rb
486
+ - test/test-id.rb
487
+ - test/test-request-timer.rb
472
488
  - test/test-request-canceler.rb
473
- - test/test-table-traverse.rb
474
- - test/test-expression-builder.rb
475
- - test/test-operator.rb
476
- - test/test-table-dumper.rb
477
- - test/test-package-label.rb
478
- - test/test-plugin.rb
479
489
  - test/test-database-dumper.rb
480
- - test/test-snippet.rb
481
- - test/test-table-arrow.rb
482
490
  - test/test-schema-create-table.rb
483
- - test/groonga-test-utils.rb
484
- - test/test-thread.rb
485
491
  - test/test-schema.rb
486
- - test/test-request-timer.rb
487
- - test/test-index-cursor.rb
488
- - test/test-column-cache.rb
489
- - test/test-config.rb
490
- - test/test-command-select.rb
491
- - test/test-table-select.rb