Constructing exec.Command objects looks up the actual binary path
If a binary is not present, then the command name will not be resolved
to a path. If the binary is on the path, then the binary name will be
adjusted. Therefore just checking for an `nft` suffix.
@@ -64,7 +64,7 @@ var _ = Describe("Common Methods", func() {
table.DescribeTable("should compose the correct command",
func(protocol iptables.Protocol, protocolVersionNum string) {
cmd := composeNftablesLoad(protocol)
- Expect(cmd.Path).To(Equal("nft"))
+ Expect(cmd.Path).To(HaveSuffix("nft"))
Expect(cmd.Args).To(Equal([]string{
"nft",
"-f",
