insomniacslk / dhcp

DHCPv6 and DHCPv4 packet library, client and server written in Go
BSD 3-Clause "New" or "Revised" License
710 stars 169 forks source link

Improving test coverage before lazy parsing #493

Closed hugelgupf closed 1 year ago

hugelgupf commented 1 year ago

Cover every part of message encoding and decoding.

Requires generics. Go 1.18.

New getters for 4RD & vendor class options

codecov[bot] commented 1 year ago

Codecov Report

Base: 0.00% // Head: 72.84% // Increases project coverage by +72.84% :tada:

Coverage data is based on head (f4fb867) compared to base (5369909). Patch coverage: 75.00% of modified lines in pull request are covered.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #493 +/- ## =========================================== + Coverage 0 72.84% +72.84% =========================================== Files 0 90 +90 Lines 0 5719 +5719 =========================================== + Hits 0 4166 +4166 - Misses 0 1381 +1381 - Partials 0 172 +172 ``` | [Impacted Files](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac) | Coverage Δ | | |---|---|---| | [dhcpv6/option\_remoteid.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L29wdGlvbl9yZW1vdGVpZC5nbw==) | `100.00% <ø> (ø)` | | | [dhcpv6/option\_temporaryaddress.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L29wdGlvbl90ZW1wb3JhcnlhZGRyZXNzLmdv) | `100.00% <ø> (ø)` | | | [dhcpv6/duid.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L2R1aWQuZ28=) | `84.61% <6.25%> (ø)` | | | [dhcpv6/option\_4rd.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L29wdGlvbl80cmQuZ28=) | `95.19% <84.21%> (ø)` | | | [dhcpv6/dhcpv6.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L2RoY3B2Ni5nbw==) | `73.72% <100.00%> (ø)` | | | [dhcpv6/dhcpv6message.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L2RoY3B2Nm1lc3NhZ2UuZ28=) | `78.80% <100.00%> (ø)` | | | [dhcpv6/option\_iapd.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L29wdGlvbl9pYXBkLmdv) | `94.33% <100.00%> (ø)` | | | [dhcpv6/option\_userclass.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L29wdGlvbl91c2VyY2xhc3MuZ28=) | `100.00% <100.00%> (ø)` | | | [dhcpv6/option\_vendorclass.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L29wdGlvbl92ZW5kb3JjbGFzcy5nbw==) | `100.00% <100.00%> (ø)` | | | [dhcpv6/options.go](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac#diff-ZGhjcHY2L29wdGlvbnMuZ28=) | `93.37% <100.00%> (ø)` | | | ... and [91 more](https://codecov.io/gh/insomniacslk/dhcp/pull/493?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac) | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=insomniac)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

hugelgupf commented 1 year ago

Stickler doesn't seem to like generics