Skip to content
Permalink
Browse files

Updated testsuite to cover bnc#914833

  • Loading branch information...
mchf committed Apr 24, 2015
1 parent 4cadf41 commit 86aa9ff6013415d64a5701bb9131ab96c28cbc97
Showing with 14 additions and 0 deletions.
  1. +14 −0 test/netcard_test.rb
@@ -236,6 +236,20 @@
end
end

describe "LanItemsClass#SetItemName" do
let(:new_name) { "new_name" }

# this test covers bnc#914833
it "doesn't try to update udev rules when none exists for the item" do
allow(LanItems)
.to receive(:Items)
.and_return(MOCKED_ITEMS)

item_id = LanItems.Items.find { |k, v| !v.has_key?("udev") }.first
expect(LanItems.SetItemName(item_id, new_name)).to eql new_name
end
end

describe "LanItemsClass#FindAndSelect" do
before(:each) do
@lan_items = Yast::LanItems

0 comments on commit 86aa9ff

Please sign in to comment.
You can’t perform that action at this time.