Skip to content

Commit

Permalink
Updated testsuite for bnc#972575
Browse files Browse the repository at this point in the history
  • Loading branch information
mchf committed May 18, 2016
1 parent b0181b0 commit 665eccc
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions library/network/test/network_interfaces_helpers_test.rb
Expand Up @@ -58,5 +58,18 @@ module Yast
end
end
end

describe "NetworkInterfaces#filter_interfacetype" do
it "drops interface type if present and not set to \"lo\" or \"dummy\"" do
devmap = { "INTERFACETYPE" => "eth" }

expect(NetworkInterfaces.filter_interfacetype(devmap)).not_to include "INTERFACETYPE"
end

it "keeps interface type if present and is set to \"lo\" or \"dummy\"" do
expect(NetworkInterfaces.filter_interfacetype({ "INTERFACETYPE" => "lo" })).to include "INTERFACETYPE"
expect(NetworkInterfaces.filter_interfacetype({ "INTERFACETYPE" => "dummy" })).to include "INTERFACETYPE"
end
end
end
end

0 comments on commit 665eccc

Please sign in to comment.