Skip to content

Fix Lint/DuplicateMethods in StringIO_test.rb#3010

Merged
soutaro merged 1 commit into
masterfrom
claude/modest-lovelace-6tmymu
Jun 22, 2026
Merged

Fix Lint/DuplicateMethods in StringIO_test.rb#3010
soutaro merged 1 commit into
masterfrom
claude/modest-lovelace-6tmymu

Conversation

@soutaro

@soutaro soutaro commented Jun 22, 2026

Copy link
Copy Markdown
Member

Summary

master's CI ("Ruby" job) is failing on RuboCop with Lint/DuplicateMethods:

Lint/DuplicateMethods: Method `StringIOTypeTest#test_pread` is defined at both test/stdlib/StringIO_test.rb:78 and test/stdlib/StringIO_test.rb:133.
Lint/DuplicateMethods: Method `StringIOTypeTest#test_read_nonblock` is defined at both test/stdlib/StringIO_test.rb:83 and test/stdlib/StringIO_test.rb:140.
Lint/DuplicateMethods: Method `StringIOTypeTest#test_sysread` is defined at both test/stdlib/StringIO_test.rb:93 and test/stdlib/StringIO_test.rb:162.

Cause

This is a merge skew (semantic conflict) between two PRs that were each green on their own:

#3002's branch last synced master at a point that did not yet contain 4de713c, so RuboCop saw no duplicate when #3002's CI ran. The duplicate only materialized once #3002 was merged into the current master, and CI is not re-run against the post-merge state.

Fix

Merge the nil output buffer assertions into the existing methods and drop the duplicate definitions. No test coverage is lost.

  • ruby -c: Syntax OK
  • No duplicate method names remain in the file.

🤖 Generated with Claude Code


Generated by Claude Code

PR #3002 added test_pread, test_read_nonblock and test_sysread that
duplicate the existing methods of the same name, breaking rubocop on
master. Merge the nil output buffer assertions into the existing
methods and drop the duplicate definitions.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01N9NBHdAQGQbyDV7M8MiTLF
@soutaro soutaro added this to the RBS 4.1 milestone Jun 22, 2026
@soutaro soutaro enabled auto-merge June 22, 2026 05:04
@ksss

ksss commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

🙏

@soutaro soutaro merged commit 954dc17 into master Jun 22, 2026
25 of 26 checks passed
@soutaro soutaro deleted the claude/modest-lovelace-6tmymu branch June 22, 2026 05:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants