Repository navigation
Refactor key actor test - #645
Merged
Merged
Conversation
This was referenced Mar 19, 2024
ima1zumi
reviewed
Mar 24, 2024
| def assert_line(expected) | ||
| expected = convert_str(expected) | ||
| assert_equal(expected, @line_editor.line) | ||
| def assert_cursor_line(before, after) |
Member
There was a problem hiding this comment.
I think assert_cursor_line is not clear regarding what it asserts. I think it would be better for this method name to include the meaning of before the cursor and after the cursor.
How about renaming it to assert_line_around_cursor?
Member
Author
There was a problem hiding this comment.
The name assert_line_around_cursor sounds good. Thanks, renamed.
tompng
force-pushed
the
refactor_key_actor_test
branch
from
March 24, 2024 09:17
cf16222 to
6376184
Compare
matzbot
pushed a commit
to ruby/ruby
that referenced
this pull request
Mar 24, 2024
(ruby/reline#645) * Add assertion assert_cursor_line to test helper * Autofix key_actor test to use assert_cursor_line * Rename the assertion to assert_line_around_cursor and remove other assertions for line and cursor ruby/reline@e4773800c6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
test_key_actor_*.rbhas these kind of ideomsWe only need this assertion.
Commits
The "Autofix" commit is done by this script https://gist.github.com/tompng/215d11c9cf2c825755960b9b934a7167
Then, manually fixed remaining things by hand.