Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
cheina97 committed Jan 11, 2024
1 parent fbea8ae commit d5d395e
Show file tree
Hide file tree
Showing 6 changed files with 64 additions and 484 deletions.
77 changes: 0 additions & 77 deletions compat_policy_test.go

This file was deleted.

142 changes: 0 additions & 142 deletions monitor_test.go

This file was deleted.

11 changes: 3 additions & 8 deletions nftables_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -454,12 +454,7 @@ func TestConfigureNAT(t *testing.T) {
t.Fatal(err)
}

dnatfirstip, err := nftables.GetFirstIPFromCIDR("20.0.0.0/24")
if err != nil {
t.Fatal(err)
}

dnatlastip, err := nftables.GetLastIPFromCIDR("20.0.0.0/24")
dnatfirstip, dnatlastip, err := nftables.GetFirstAndLastIPFromCIDR("20.0.0.0/24")
if err != nil {
t.Fatal(err)
}
Expand Down Expand Up @@ -488,11 +483,11 @@ func TestConfigureNAT(t *testing.T) {
},
&expr.Immediate{
Register: 1,
Data: *dnatfirstip,
Data: dnatfirstip,
},
&expr.Immediate{
Register: 2,
Data: *dnatlastip,
Data: dnatlastip,
},
&expr.NAT{
Type: expr.NATTypeDestNAT,
Expand Down
Loading

0 comments on commit d5d395e

Please sign in to comment.