-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add GECOS field on UNIX systems. #13
Conversation
Hmm... Why is it a |
Good point, we don't need the |
ca140e2
to
b3a54cb
Compare
Done. Should I add some tests around this? I could not find any tests related to |
There's a general lack of unit tests for the core functionality in the crate, and I think it'd be best to address this in a separate PR, For the sake of consistency I'd leave this PR as-is. I assume you've tested everything manually. Anyway, LGTM. Erm... so I'm not really the maintainer, so you've got to wait for @gierens who seems to be running the place. Should take about a week from my experience. |
Noted. Yes, I have tested manually from different NSS providers, and things were fine. 👍 Could not test on BSD, though. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey guys, sorry for the late reply, been a little busy lately.
Thanks for the contribution, this looks good to me. The only thing that also was mnetioned would be testing. Sure, @OLEGSHA you are correct, there is a lack of tests ... but we have to start somewhere, so it would be great if you could add tests for this @apognu
Sure thing! I'll add a few by tomorrow and push again. |
I added a few (mocked) tests, and edited the debug print one. We are in the same situation, unfortunately, as with the other cases where I cannot assume a user on the system, or the current user, will have a comment specified (or even verify it). So short of refactoring the tests to use something like |
I'll see what happens with #15. If it gets merged, I'll add mocked tests related to this PR as well. |
cde22bf
to
2bdde60
Compare
Alright, #15 is merged, thanks again! And I took care of the minor merge conflict with the main branch. You should be good to go! :) |
Oh I got my numbers mixed, I thought this one was merged, I can rebase this properly if you want. |
If you want, got for it. But I think it's also fine the way it is. I'm not thaaaat nitpicky. At least not until the conventional commits workflow it merged haha ... just joking |
2bdde60
to
7d77044
Compare
7d77044
to
8e84fee
Compare
Mmm, I think I messed up my rebase somehow, it pulled a commit from EDIT: ok now it should merge cleanly. 🤞 |
ca57ff8
to
c6bcc9d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great! Thanks for your contribution. LGTM
This pull request adds the comment field (GECOS) that should be present on UNIX systems to the
UserExtras
struct as anOption<OsString>
. The field would beNone
if the field is empty.Refers to #12.