Closed tongsean9807 closed 4 months ago
Output:
Attention: Patch coverage is 71.69811%
with 15 lines
in your changes missing coverage. Please review.
Project coverage is 71.29%. Comparing base (
650935d
) to head (93ba577
). Report is 250 commits behind head on main.
Files | Patch % | Lines |
---|---|---|
internal/local/info.go | 71.15% | 10 Missing and 5 partials :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Hi,
I have move the GetOSIPAddress() to internal/local/info.go Let me know what other changes is needed.
I will squash them after fixing all the changes.
Thank you
@tongsean9807 looks good to me. You think you can muster up a unit test or two? Additionally, the commit message should really be feat: since its a new capability added to the cli.
Hi,
I have changed the space to tab, which causes the misalignment when viewing in github. I have added the unittest but I am unable to overwrite the net.interface. Let me know if there are better ways to improve the unittest.
Thank you
Hi @tongsean9807 , Thank you for adding the unit test! I should have sent this to you, we have a NetEnumerator
https://github.com/open-amt-cloud-toolkit/rpc-go/blob/bacb0ebc9fff12a92ccaeae5ddca8123f717fe2a/internal/flags/flags.go#L30-L31 that you can use to abstract the net.Interfaces calls.
Can take a look at https://github.com/open-amt-cloud-toolkit/rpc-go/blob/bacb0ebc9fff12a92ccaeae5ddca8123f717fe2a/internal/flags/flags_test.go#L115 for an example of how it is used in tests.
For the code that uses the NetEnumerator
check out: https://github.com/open-amt-cloud-toolkit/rpc-go/blob/bacb0ebc9fff12a92ccaeae5ddca8123f717fe2a/internal/flags/maintenance.go#L196.
Hi,
I have add positive and negative unit test. And use the net enumerator from flags package.
Thank you for the pointing out the net enumerator.
Regards, Sean
Hi @rsdmike,
I hope you're doing well. I want to follow up on this PR. I have made the changes. Have you had a chance to review it?
Thank you
Hi @rsdmike,
I hope you're doing well. I want to follow up on this PR. I have made the changes. Have you had a chance to review it?
Thank you
Thanks for following up, looks good to me! We'll get it merged.
Add os ipaddress to amtinfo command. amtinfo command now show amt ipaddrss and os ipaddress. os ipadress select by mapping to mac address from amt.
Resolves: #467