redi_search 2.0.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/lint.yml +20 -0
- data/.github/workflows/tests.yml +44 -0
- data/.rubocop.yml +67 -33
- data/Gemfile +1 -1
- data/README.md +1 -1
- data/lib/redi_search.rb +2 -0
- data/lib/redi_search/log_subscriber.rb +2 -2
- data/lib/redi_search/schema/field.rb +2 -3
- data/lib/redi_search/search.rb +1 -0
- data/lib/redi_search/version.rb +1 -1
- data/redi_search.gemspec +1 -1
- metadata +7 -6
- data/.travis.yml +0 -63
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7b7bc12a1d3a50de259ae10c27658e164d3ef84b65f0c4108c925138e53c1239
|
4
|
+
data.tar.gz: 899ac067a70ee3f5d43c833a59aa32546ca4e18a57beaba3bccabc496ffff96a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 131f1b1c9a4e2dad0740da6398a41a5ea01725e6e7dc02b9d604b252d3ad2612d3d23946fa1029e2d897c879b9b8c1c2951a73b1d7e4bca415d65998c0d8d0b8
|
7
|
+
data.tar.gz: c1a6d747b27f77054c797feee442359306a36609fe1d8d8483467df93916ea4b2e7af7a1db5c3bd442aba04e54dad0131ac673dc6aa10ddba89b63ef48dbad37
|
@@ -0,0 +1,20 @@
|
|
1
|
+
name: lint
|
2
|
+
|
3
|
+
on: [push]
|
4
|
+
|
5
|
+
jobs:
|
6
|
+
lint:
|
7
|
+
runs-on: ubuntu-latest
|
8
|
+
steps:
|
9
|
+
- uses: actions/checkout@v1
|
10
|
+
- name: Set up Ruby 2.7
|
11
|
+
uses: actions/setup-ruby@v1
|
12
|
+
with:
|
13
|
+
ruby-version: 2.7.x
|
14
|
+
- name: Install dependencies
|
15
|
+
run: |
|
16
|
+
sudo apt-get install libsqlite3-dev
|
17
|
+
gem install bundler --no-document
|
18
|
+
bundle install
|
19
|
+
- name: Run tests
|
20
|
+
run: bundle exec rubocop --config=./.rubocop.yml --parallel
|
@@ -0,0 +1,44 @@
|
|
1
|
+
name: tests
|
2
|
+
|
3
|
+
on: [push]
|
4
|
+
|
5
|
+
jobs:
|
6
|
+
unit:
|
7
|
+
runs-on: ubuntu-latest
|
8
|
+
strategy:
|
9
|
+
matrix:
|
10
|
+
ruby: [ '2.5.x', '2.6.x', '2.7.x' ]
|
11
|
+
gemfile: [ 'Gemfile', 'gemfiles/activerecord_51.gemfile', 'gemfiles/activerecord_52.gemfile' ]
|
12
|
+
steps:
|
13
|
+
- uses: actions/checkout@v1
|
14
|
+
- name: Set up Ruby ${{ matrix.ruby }}
|
15
|
+
uses: actions/setup-ruby@v1
|
16
|
+
with:
|
17
|
+
ruby-version: ${{ matrix.ruby }}
|
18
|
+
- name: Install dependencies
|
19
|
+
run: |
|
20
|
+
sudo apt-get install libsqlite3-dev -y
|
21
|
+
gem install bundler --no-document
|
22
|
+
BUNDLE_GEMFILE=${{ matrix.gemfile }} bundle install
|
23
|
+
- name: Run tests
|
24
|
+
run: BUNDLE_GEMFILE=${{ matrix.gemfile }} bundle exec rake test:unit
|
25
|
+
integration:
|
26
|
+
runs-on: ubuntu-latest
|
27
|
+
strategy:
|
28
|
+
matrix:
|
29
|
+
redi_search: [ '1.4.28', '1.6.13', 'edge' ]
|
30
|
+
steps:
|
31
|
+
- uses: actions/checkout@v1
|
32
|
+
- name: Set up Ruby 2.7
|
33
|
+
uses: actions/setup-ruby@v1
|
34
|
+
with:
|
35
|
+
ruby-version: 2.7.x
|
36
|
+
- name: Install dependencies
|
37
|
+
run: |
|
38
|
+
sudo apt-get install libsqlite3-dev -y
|
39
|
+
gem install bundler --no-document
|
40
|
+
bundle install
|
41
|
+
docker run -d -p 6379:6379 redislabs/redisearch:${{ matrix.redi_search }} --protected-mode no --loadmodule /usr/lib/redis/modules/redisearch.so
|
42
|
+
- name: Run tests
|
43
|
+
run: |
|
44
|
+
bundle exec rake test:integration
|
data/.rubocop.yml
CHANGED
@@ -35,16 +35,16 @@ Layout/AccessModifierIndentation:
|
|
35
35
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#indent-public-private-protected
|
36
36
|
Enabled: false
|
37
37
|
|
38
|
-
Layout/
|
38
|
+
Layout/ArrayAlignment:
|
39
39
|
Description: Align the elements of an array literal if they span more than one line.
|
40
40
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#align-multiline-arrays
|
41
41
|
Enabled: true
|
42
42
|
|
43
|
-
Layout/
|
43
|
+
Layout/HashAlignment:
|
44
44
|
Description: Align the elements of a hash literal if they span more than one line.
|
45
45
|
Enabled: true
|
46
46
|
|
47
|
-
Layout/
|
47
|
+
Layout/ParameterAlignment:
|
48
48
|
Description: Align the parameters of a method call if they span more than one line.
|
49
49
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-double-indent
|
50
50
|
Enabled: true
|
@@ -150,7 +150,7 @@ Layout/InitialIndentation:
|
|
150
150
|
Description: Checks the indentation of the first non-blank non-comment line in a file.
|
151
151
|
Enabled: false
|
152
152
|
|
153
|
-
Layout/
|
153
|
+
Layout/FirstArgumentIndentation:
|
154
154
|
Description: Checks the indentation of the first parameter in a method call.
|
155
155
|
Enabled: false
|
156
156
|
|
@@ -164,19 +164,19 @@ Layout/IndentationWidth:
|
|
164
164
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-indentation
|
165
165
|
Enabled: true
|
166
166
|
|
167
|
-
Layout/
|
167
|
+
Layout/FirstArrayElementIndentation:
|
168
168
|
Description: Checks the indentation of the first element in an array literal.
|
169
169
|
Enabled: false
|
170
170
|
|
171
|
-
Layout/
|
171
|
+
Layout/AssignmentIndentation:
|
172
172
|
Description: Checks the indentation of the first line of the right-hand-side of a multi-line assignment.
|
173
173
|
Enabled: true
|
174
174
|
|
175
|
-
Layout/
|
175
|
+
Layout/FirstHashElementIndentation:
|
176
176
|
Description: Checks the indentation of the first key in a hash literal.
|
177
177
|
Enabled: false
|
178
178
|
|
179
|
-
Layout/
|
179
|
+
Layout/HeredocIndentation:
|
180
180
|
Description: This cops checks the indentation of the here document bodies.
|
181
181
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#squiggly-heredocs
|
182
182
|
Enabled: true
|
@@ -327,12 +327,15 @@ Layout/SpaceInsideStringInterpolation:
|
|
327
327
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#string-interpolation
|
328
328
|
Enabled: false
|
329
329
|
|
330
|
-
Layout/
|
330
|
+
Layout/IndentationStyle:
|
331
331
|
Description: No hard tabs.
|
332
332
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#spaces-indentation
|
333
333
|
Enabled: false
|
334
334
|
|
335
|
-
Layout/
|
335
|
+
Layout/SpaceAroundMethodCallOperator:
|
336
|
+
Enabled: true
|
337
|
+
|
338
|
+
Layout/TrailingEmptyLines:
|
336
339
|
Description: Checks trailing blank lines and final newline.
|
337
340
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#newline-eof
|
338
341
|
Enabled: false
|
@@ -399,7 +402,7 @@ Lint/DuplicateMethods:
|
|
399
402
|
Description: Check for duplicate method definitions.
|
400
403
|
Enabled: true
|
401
404
|
|
402
|
-
Lint/
|
405
|
+
Lint/DuplicateHashKey:
|
403
406
|
Description: Check for duplicate keys in hash literals.
|
404
407
|
Enabled: true
|
405
408
|
|
@@ -432,10 +435,6 @@ Layout/EndAlignment:
|
|
432
435
|
Description: Align ends correctly.
|
433
436
|
Enabled: true
|
434
437
|
|
435
|
-
Lint/EndInMethod:
|
436
|
-
Description: END blocks should not be placed inside method definitions.
|
437
|
-
Enabled: true
|
438
|
-
|
439
438
|
Lint/EnsureReturn:
|
440
439
|
Description: Do not use return in an ensure block.
|
441
440
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-return-ensure
|
@@ -449,7 +448,7 @@ Lint/FormatParameterMismatch:
|
|
449
448
|
Description: The number of parameters to format/sprint must match the fields.
|
450
449
|
Enabled: true
|
451
450
|
|
452
|
-
Lint/
|
451
|
+
Lint/SuppressedException:
|
453
452
|
Description: Don't suppress exception.
|
454
453
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#dont-hide-exceptions
|
455
454
|
Enabled: true
|
@@ -483,7 +482,7 @@ Lint/Loop:
|
|
483
482
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#loop-with-break
|
484
483
|
Enabled: true
|
485
484
|
|
486
|
-
Lint/
|
485
|
+
Lint/MultipleComparison:
|
487
486
|
Description: Use `&&` operator to compare multiple value.
|
488
487
|
Enabled: true
|
489
488
|
|
@@ -558,7 +557,7 @@ Lint/ShadowingOuterLocalVariable:
|
|
558
557
|
Description: Do not use the same name as outer local variable for block arguments or block local variables.
|
559
558
|
Enabled: true
|
560
559
|
|
561
|
-
Lint/
|
560
|
+
Lint/RedundantStringCoercion:
|
562
561
|
Description: Checks for Object#to_s usage in string interpolation.
|
563
562
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-to-s
|
564
563
|
Enabled: true
|
@@ -571,11 +570,11 @@ Lint/UnifiedInteger:
|
|
571
570
|
Description: Use Integer instead of Fixnum or Bignum
|
572
571
|
Enabled: true
|
573
572
|
|
574
|
-
Lint/
|
573
|
+
Lint/RedundantRequireStatement:
|
575
574
|
Description: Checks for unnecessary `require` statement.
|
576
575
|
Enabled: true
|
577
576
|
|
578
|
-
Lint/
|
577
|
+
Lint/RedundantSplatExpansion:
|
579
578
|
Description: Checks for splat unnecessarily being called on literals
|
580
579
|
Enabled: true
|
581
580
|
|
@@ -646,7 +645,6 @@ Metrics/BlockLength:
|
|
646
645
|
- Rakefile
|
647
646
|
- "**/*.rake"
|
648
647
|
- spec/**/*.rb
|
649
|
-
- 'config/routes.rb'
|
650
648
|
- 'config/environments/*.rb'
|
651
649
|
|
652
650
|
Metrics/BlockNesting:
|
@@ -664,12 +662,15 @@ Metrics/CyclomaticComplexity:
|
|
664
662
|
Description: A complexity metric that is strongly correlated to the number of test cases needed to validate a method.
|
665
663
|
Enabled: true
|
666
664
|
|
667
|
-
|
665
|
+
Layout/LineLength:
|
668
666
|
Description: Limit lines to 80 characters.
|
669
667
|
StyleGuide: '#80-character-limits'
|
670
668
|
Enabled: true
|
669
|
+
Max: 80
|
671
670
|
Exclude:
|
672
671
|
- 'db/**/*'
|
672
|
+
- 'config/initializers/**/*'
|
673
|
+
- 'config/environments/**/*'
|
673
674
|
|
674
675
|
Metrics/MethodLength:
|
675
676
|
Description: Avoid methods longer than 10 lines of code.
|
@@ -773,13 +774,13 @@ Performance/CaseWhenSplat:
|
|
773
774
|
|
774
775
|
Performance/Count:
|
775
776
|
Description: Use `count` instead of `select...size`, `reject...size`, `select...count`, `reject...count`, `select...length`, and `reject...length`.
|
776
|
-
|
777
|
+
SafeAutoCorrect: true
|
777
778
|
Enabled: true
|
778
779
|
|
779
780
|
Performance/Detect:
|
780
781
|
Description: Use `detect` instead of `select.first`, `find_all.first`, `select.last`, and `find_all.last`.
|
781
782
|
Reference: 'https://github.com/JuanitoFatas/fast-ruby#enumerabledetect-vs-enumerableselectfirst-code'
|
782
|
-
|
783
|
+
SafeAutoCorrect: true
|
783
784
|
Enabled: true
|
784
785
|
|
785
786
|
Performance/DoubleStartEndWith:
|
@@ -821,6 +822,9 @@ Performance/RedundantMerge:
|
|
821
822
|
Reference: https://github.com/JuanitoFatas/fast-ruby#hashmerge-vs-hash-code
|
822
823
|
Enabled: true
|
823
824
|
|
825
|
+
Style/ExponentialNotation:
|
826
|
+
Enabled: true
|
827
|
+
|
824
828
|
Style/RedundantSortBy:
|
825
829
|
Description: Use `sort` instead of `sort_by { |x| x }`.
|
826
830
|
Enabled: true
|
@@ -946,10 +950,6 @@ Style/BlockDelimiters:
|
|
946
950
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#single-line-blocks
|
947
951
|
Enabled: true
|
948
952
|
|
949
|
-
Style/BracesAroundHashParameters:
|
950
|
-
Description: Enforce braces style around hash parameters.
|
951
|
-
Enabled: false
|
952
|
-
|
953
953
|
Style/CaseEquality:
|
954
954
|
Description: Avoid explicit use of the case equality operator(===).
|
955
955
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-case-equality
|
@@ -1073,7 +1073,7 @@ Style/EmptyMethod:
|
|
1073
1073
|
Style/EndBlock:
|
1074
1074
|
Description: Avoid the use of END blocks.
|
1075
1075
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-END-blocks
|
1076
|
-
Enabled:
|
1076
|
+
Enabled: true
|
1077
1077
|
|
1078
1078
|
Style/Encoding:
|
1079
1079
|
Description: Use UTF-8 as the source file encoding.
|
@@ -1256,7 +1256,7 @@ Style/MultipleComparison:
|
|
1256
1256
|
|
1257
1257
|
Style/MutableConstant:
|
1258
1258
|
Description: Do not assign mutable objects to constants.
|
1259
|
-
Enabled:
|
1259
|
+
Enabled: false
|
1260
1260
|
|
1261
1261
|
Style/NegatedIf:
|
1262
1262
|
Description: Favor unless over if for negative conditions (or control flow or).
|
@@ -1547,15 +1547,15 @@ Style/UnlessElse:
|
|
1547
1547
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#no-else-with-unless
|
1548
1548
|
Enabled: true
|
1549
1549
|
|
1550
|
-
Style/
|
1550
|
+
Style/RedundantCapitalW:
|
1551
1551
|
Description: Checks for %W when interpolation is not needed.
|
1552
1552
|
Enabled: false
|
1553
1553
|
|
1554
|
-
Style/
|
1554
|
+
Style/RedundantInterpolation:
|
1555
1555
|
Description: Checks for strings that are just an interpolated expression.
|
1556
1556
|
Enabled: true
|
1557
1557
|
|
1558
|
-
Style/
|
1558
|
+
Style/RedundantPercentQ:
|
1559
1559
|
Description: Checks for %q/%Q when single quotes or double quotes would do.
|
1560
1560
|
StyleGuide: https://github.com/bbatsov/ruby-style-guide#percent-q
|
1561
1561
|
Enabled: false
|
@@ -1598,3 +1598,37 @@ Style/YodaCondition:
|
|
1598
1598
|
Style/ZeroLengthPredicate:
|
1599
1599
|
Description: Use #empty? when testing for objects of length 0.
|
1600
1600
|
Enabled: true
|
1601
|
+
|
1602
|
+
Lint/RaiseException:
|
1603
|
+
Description: Checks for `raise` or `fail` statements which are raising `Exception` class.
|
1604
|
+
Enabled: true
|
1605
|
+
Lint/StructNewOverride:
|
1606
|
+
Description: 'Disallow overriding the `Struct` built-in methods via `Struct.new`.'
|
1607
|
+
Enabled: true
|
1608
|
+
Style/HashEachMethods:
|
1609
|
+
Description: 'Use Hash#each_key and Hash#each_value.'
|
1610
|
+
Enabled: true
|
1611
|
+
Safe: false
|
1612
|
+
Style/HashTransformKeys:
|
1613
|
+
Description: 'Prefer `transform_keys` over `each_with_object` and `map`.'
|
1614
|
+
Enabled: true
|
1615
|
+
Safe: false
|
1616
|
+
Style/HashTransformValues:
|
1617
|
+
Description: 'Prefer `transform_values` over `each_with_object` and `map`.'
|
1618
|
+
Enabled: true
|
1619
|
+
Safe: false
|
1620
|
+
|
1621
|
+
Layout/EmptyLinesAroundAttributeAccessor:
|
1622
|
+
Enabled: true
|
1623
|
+
Lint/DeprecatedOpenSSLConstant:
|
1624
|
+
Enabled: true
|
1625
|
+
Style/SlicingWithRange:
|
1626
|
+
Enabled: true
|
1627
|
+
Lint/MixedRegexpCaptureTypes:
|
1628
|
+
Enabled: true
|
1629
|
+
Style/RedundantRegexpCharacterClass:
|
1630
|
+
Enabled: true
|
1631
|
+
Style/RedundantRegexpEscape:
|
1632
|
+
Enabled: true
|
1633
|
+
Style/RedundantFetchBlock:
|
1634
|
+
Enabled: true
|
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
|
7
7
|
# RediSearch
|
8
8
|
|
9
|
-
|
9
|
+
![Build Status](https://github.com/npezza93/redi_search/workflows/tests/badge.svg)
|
10
10
|
[![Test Coverage](https://api.codeclimate.com/v1/badges/c6437acac5684de2549d/test_coverage)](https://codeclimate.com/github/npezza93/redi_search/test_coverage)
|
11
11
|
[![Maintainability](https://api.codeclimate.com/v1/badges/c6437acac5684de2549d/maintainability)](https://codeclimate.com/github/npezza93/redi_search/maintainability)
|
12
12
|
|
data/lib/redi_search.rb
CHANGED
@@ -35,7 +35,7 @@ module RediSearch
|
|
35
35
|
color("#{event.payload[:name]} (#{event.duration.round(1)}ms)", RED, true)
|
36
36
|
end
|
37
37
|
|
38
|
-
# rubocop:disable Metrics/
|
38
|
+
# rubocop:disable Metrics/MethodLength
|
39
39
|
def action_color(action)
|
40
40
|
case action.to_sym
|
41
41
|
when :search, :spellcheck then YELLOW
|
@@ -46,7 +46,7 @@ module RediSearch
|
|
46
46
|
when :explaincli then BLUE
|
47
47
|
end
|
48
48
|
end
|
49
|
-
# rubocop:enable Metrics/
|
49
|
+
# rubocop:enable Metrics/MethodLength
|
50
50
|
|
51
51
|
def command_string(event)
|
52
52
|
event.payload[:query].flatten.map.with_index do |arg, i|
|
@@ -11,9 +11,8 @@ module RediSearch
|
|
11
11
|
|
12
12
|
def boolean_options_string
|
13
13
|
boolean_options.map do |option|
|
14
|
-
|
15
|
-
|
16
|
-
end
|
14
|
+
option.to_s.upcase.split("_").join unless
|
15
|
+
FALSES.include?(send(option))
|
17
16
|
end.compact
|
18
17
|
end
|
19
18
|
end
|
data/lib/redi_search/search.rb
CHANGED
data/lib/redi_search/version.rb
CHANGED
data/redi_search.gemspec
CHANGED
@@ -31,5 +31,5 @@ Gem::Specification.new do |spec|
|
|
31
31
|
|
32
32
|
spec.add_development_dependency "bundler", ">= 1.17", "< 3"
|
33
33
|
spec.add_development_dependency "minitest", "~> 5.0"
|
34
|
-
spec.add_development_dependency "rake", "~>
|
34
|
+
spec.add_development_dependency "rake", "~> 13.0"
|
35
35
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: redi_search
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nick Pezza
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-06-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -90,14 +90,14 @@ dependencies:
|
|
90
90
|
requirements:
|
91
91
|
- - "~>"
|
92
92
|
- !ruby/object:Gem::Version
|
93
|
-
version: '
|
93
|
+
version: '13.0'
|
94
94
|
type: :development
|
95
95
|
prerelease: false
|
96
96
|
version_requirements: !ruby/object:Gem::Requirement
|
97
97
|
requirements:
|
98
98
|
- - "~>"
|
99
99
|
- !ruby/object:Gem::Version
|
100
|
-
version: '
|
100
|
+
version: '13.0'
|
101
101
|
description:
|
102
102
|
email: npezza93@gmail.com
|
103
103
|
executables: []
|
@@ -107,9 +107,10 @@ files:
|
|
107
107
|
- ".github/ISSUE_TEMPLATE/bug_report.md"
|
108
108
|
- ".github/ISSUE_TEMPLATE/feature_request.md"
|
109
109
|
- ".github/logo.svg"
|
110
|
+
- ".github/workflows/lint.yml"
|
111
|
+
- ".github/workflows/tests.yml"
|
110
112
|
- ".gitignore"
|
111
113
|
- ".rubocop.yml"
|
112
|
-
- ".travis.yml"
|
113
114
|
- Appraisals
|
114
115
|
- CODE_OF_CONDUCT.md
|
115
116
|
- Gemfile
|
@@ -193,7 +194,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
193
194
|
- !ruby/object:Gem::Version
|
194
195
|
version: '0'
|
195
196
|
requirements: []
|
196
|
-
rubygems_version: 3.
|
197
|
+
rubygems_version: 3.1.2
|
197
198
|
signing_key:
|
198
199
|
specification_version: 4
|
199
200
|
summary: RediSearch ruby wrapper that can integrate with Rails
|
data/.travis.yml
DELETED
@@ -1,63 +0,0 @@
|
|
1
|
-
---
|
2
|
-
env:
|
3
|
-
global:
|
4
|
-
- CC_TEST_REPORTER_ID=fec34310f03fd2cc767a85fa23d5102f3dca67b9cc967a48d9940027731394e8
|
5
|
-
sudo: false
|
6
|
-
language: ruby
|
7
|
-
cache:
|
8
|
-
directories:
|
9
|
-
- gemfiles/vendor/bundle
|
10
|
-
- /home/travis/.rvm/
|
11
|
-
services: docker
|
12
|
-
jobs:
|
13
|
-
include:
|
14
|
-
- stage: Integration Tests
|
15
|
-
script: |
|
16
|
-
docker run -d -p 6379:6379 redislabs/redisearch:1.4.12 --protected-mode no --loadmodule /usr/lib/redis/modules/redisearch.so
|
17
|
-
bundle exec rake test:integration
|
18
|
-
rvm: 2.6
|
19
|
-
gemfile: Gemfile
|
20
|
-
name: RediSearch 1.4.12
|
21
|
-
- stage: Integration Tests
|
22
|
-
script: |
|
23
|
-
docker run -d -p 6379:6379 redislabs/redisearch:1.4.11 --protected-mode no --loadmodule /usr/lib/redis/modules/redisearch.so
|
24
|
-
bundle exec rake test:integration
|
25
|
-
rvm: 2.6
|
26
|
-
gemfile: Gemfile
|
27
|
-
name: RediSearch 1.4.11
|
28
|
-
- stage: Integration Tests
|
29
|
-
script: |
|
30
|
-
docker run -d -p 6379:6379 redislabs/redisearch:1.4.10 --protected-mode no --loadmodule /usr/lib/redis/modules/redisearch.so
|
31
|
-
bundle exec rake test:integration
|
32
|
-
rvm: 2.6
|
33
|
-
gemfile: Gemfile
|
34
|
-
name: RediSearch 1.4.10
|
35
|
-
- stage: Unit Tests
|
36
|
-
script: |
|
37
|
-
curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
|
38
|
-
chmod +x ./cc-test-reporter
|
39
|
-
./cc-test-reporter before-build
|
40
|
-
bundle exec rake test:unit
|
41
|
-
if [[ "$TRAVIS_TEST_RESULT" == 0 ]]; then ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT; fi
|
42
|
-
rvm: 2.6
|
43
|
-
gemfile: Gemfile
|
44
|
-
name: Ruby 2.6 and Rails 6.0rc2
|
45
|
-
- stage: Unit Tests
|
46
|
-
script: bundle exec rake test:unit
|
47
|
-
rvm: 2.6
|
48
|
-
gemfile: gemfiles/activerecord_52.gemfile
|
49
|
-
name: Ruby 2.6 and Rails 5.2
|
50
|
-
- stage: Unit Tests
|
51
|
-
script: bundle exec rake test:unit
|
52
|
-
rvm: 2.6
|
53
|
-
gemfile: gemfiles/activerecord_51.gemfile
|
54
|
-
name: Ruby 2.6 and Rails 5.1
|
55
|
-
- stage: Unit Tests
|
56
|
-
script: bundle exec rake test:unit
|
57
|
-
rvm: 2.5
|
58
|
-
gemfile: Gemfile
|
59
|
-
name: Ruby 2.5 and Rails 6.0rc2
|
60
|
-
- stage: Lint
|
61
|
-
script: bundle exec rubocop --config=./.rubocop.yml
|
62
|
-
rvm: 2.6
|
63
|
-
name: Rubocop
|