fix(sleep): use uucore's from_str to support parsing hex#7675
fix(sleep): use uucore's from_str to support parsing hex#7675RenjiSann merged 2 commits intouutils:mainfrom
Conversation
fdcaee4 to
c42569e
Compare
c42569e to
c05b05d
Compare
|
GNU testsuite comparison: |
c6ec491 to
471e100
Compare
|
GNU testsuite comparison: |
|
GNU testsuite comparison: |
There was a problem hiding this comment.
Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.
Comments suppressed due to low confidence (1)
tests/by-util/test_sleep.rs:243
- The test function name suggests no error is expected, but the test asserts failure by calling
.fails(). Consider renaming the test (for example, to test_sleep_when_input_has_trailing_whitespace_then_error) to more accurately reflect its behavior.
fn test_sleep_when_input_has_trailing_whitespace_then_no_error(#[case] input: &str) {
|
GNU testsuite comparison: |
drinkcat
left a comment
There was a problem hiding this comment.
Thank you!! I think it looks quite good (I was afraid it'd look worse than that ,-P)! Just a few nits.
|
Oh, one more thing, please squash your commits into logical units (1 big commit would be ok, or maybe a couple: one for |
|
@drinkcat There should be an option to "squash and merge", which will combine all of my changes into one commit (possibly two with a merge commit). If it's easier for you, I'm happy to make one commit on my end. |
9e807b4 to
5033605
Compare
|
GNU testsuite comparison: |
|
Thanks! I think this looks good now.
I'll let @sylvestre or @cakebaker comment. |
|
I've confirmed that this would close #7678, but the relevant tests aren't there yet. This implementation of However, I don't want this PR to get too much scope creep. Should I add these two features here, or should I wait for this PR to get merged and then branch off of main for the other two? |
|
GNU testsuite comparison: |
As a good practice, I usually make 2 commits (unless I'm pushing a massive refactor which needs separate commits) : One for the changes, one for the tests. This is not possible to do using Github's interface, hence the request to squash the commits on your side. Thank you ! |
|
GNU testsuite comparison: |
kudos :) |
b80dd49 to
7f2fb04
Compare
|
GNU testsuite comparison: |
|
Thanks ! |
|
@Qelxiros as you touched this, maybe you could also remove the fundu dependency here too: coreutils/src/uu/tail/src/args.rs Line 231 in 82f354f |
Not that crazy anymore, fixed by uutils#7675.
Not that crazy anymore, fixed by uutils#7675.
closes #7669
sleepnow uses uucore'sfrom_strinstead offunduto support hex parsing. This changes some error output (although it looks to be more in line with GNU, not less), so I changed the relevant tests as well. However, at first glance, it looks like it might be returning "empty string" in unexpected cases (e.g. '\n').