Skip to content

Commit c7964d7

Browse files
authored
Merge pull request #1021 from suketa/fix-rubocop-predicate-methods
fix rubocop.
2 parents 707a1e8 + 19996dc commit c7964d7

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

test/duckdb_test/result_test.rb

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def test_each_without_block
4141
result = @con.query('SELECT * from table1')
4242

4343
expected_ary = [
44-
expected_boolean,
44+
expected_bool_true,
4545
expected_smallint,
4646
expected_integer,
4747
expected_bigint,
@@ -52,15 +52,15 @@ def test_each_without_block
5252
Date.parse(expected_date),
5353
Time.parse(expected_timestamp),
5454
expected_blob,
55-
expected_boolean_false
55+
expected_bool_false
5656
]
5757

5858
assert_equal([expected_ary, 0], result.each.with_index.to_a.first)
5959
end
6060
# rubocop:enable Metrics/AbcSize, Metrics/MethodLength
6161

6262
def test_result_boolean
63-
assert_equal(expected_boolean, @ary[0])
63+
assert_equal(expected_bool_true, @ary[0])
6464
end
6565

6666
def test_result_smallint
@@ -232,7 +232,7 @@ def insert_sql
232232
<<-SQL
233233
INSERT INTO table1 VALUES
234234
(
235-
#{expected_boolean},
235+
#{expected_bool_true},
236236
#{expected_smallint},
237237
#{expected_integer},
238238
#{expected_bigint},
@@ -243,17 +243,17 @@ def insert_sql
243243
'#{expected_date}',
244244
'#{expected_timestamp}',
245245
'#{expected_blob}',
246-
'#{expected_boolean_false}'
246+
'#{expected_bool_false}'
247247
),
248248
(NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL)
249249
SQL
250250
end
251251

252-
def expected_boolean
252+
def expected_bool_true # rubocop:disable Naming/PredicateMethod
253253
true
254254
end
255255

256-
def expected_boolean_false
256+
def expected_bool_false # rubocop:disable Naming/PredicateMethod
257257
false
258258
end
259259

0 commit comments

Comments
 (0)