Skip to content

Backport(v1.19): test_extractor: fix Rubocop error (#5506) - #5507

Merged
Watson1978 merged 1 commit into
v1.19from
backport-to-v1.19/pr5506
Sep 28, 2026
Merged

Watson1978 merged 1 commit into
v1.19from
backport-to-v1.19/pr5506

Conversation

@github-actions

Copy link
Copy Markdown

Which issue(s) this PR fixes:
Backport #5506
Fixes #

What this PR does / why we need it:
This fix following error:

test/plugin/test_extractor.rb:40:5: C: [Correctable] Performance/TimesMap: Use Array.new(size) with a block instead of .times.map only if size is always 0 or more.
    size.times.map { random.rand(36).to_s(36) }.join
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

460 files inspected, 1 offense detected, 1 more offense can be corrected with `rubocop -A`

Docs Changes:

Release Note:

**Which issue(s) this PR fixes**:
Fixes #

**What this PR does / why we need it**:
This fix following error:

```
test/plugin/test_extractor.rb:40:5: C: [Correctable] Performance/TimesMap: Use Array.new(size) with a block instead of .times.map only if size is always 0 or more.
    size.times.map { random.rand(36).to_s(36) }.join
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

460 files inspected, 1 offense detected, 1 more offense can be corrected with `rubocop -A`
```

**Docs Changes**:

**Release Note**:

Signed-off-by: Shizuo Fujita <fujita@clear-code.com>
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
@Watson1978 Watson1978 added the CI Test/CI issues label Sep 28, 2026
@Watson1978
Watson1978 merged commit 625625b into v1.19 Sep 28, 2026
20 of 21 checks passed
@Watson1978
Watson1978 deleted the backport-to-v1.19/pr5506 branch September 28, 2026 05:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CI Test/CI issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant