Skip to content

Commit

Permalink
Fix FormController test
Browse files Browse the repository at this point in the history
  • Loading branch information
imobachgs committed Jan 23, 2019
1 parent ae2681c commit 171b3bc
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/y2configuration_management/salt/form_controller_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -215,8 +215,10 @@
let(:element_locator) { locator_from_string(".person.computers[1]") }

it "removes an element" do
expect(data).to receive(:remove_item).with(locator_from_string(".root.person.computers[1]"))
controller.remove(element_locator)
expect { controller.remove(element_locator) }
.to change { controller.get(locator_from_string(".root.person.computers[1]")) }
.from(Hash)
.to(nil)
end
end

Expand Down

0 comments on commit 171b3bc

Please sign in to comment.