Skip to content

Commit

Permalink
Updates from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
imobachgs committed May 27, 2016
1 parent fb66204 commit d52940a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
5 changes: 3 additions & 2 deletions src/lib/installation/clients/ssh_import_auto.rb
Expand Up @@ -53,7 +53,7 @@ def import(data)
def summary
message =
if ssh_importer.configurations.empty?
_("No previous Linux installation found - not importing any SSH Key")
_("No previous Linux installation found")
elsif ssh_importer.device.nil?
_("No existing SSH host keys will be copied")
else
Expand All @@ -68,7 +68,8 @@ def summary
_("SSH host keys will be copied from %s") % name
end
end
"<UL>#{message}</UL>"
# FIXME: we should use the Summary module.
"<UL><LI>#{message}</LI></UL>"
end

def modified?
Expand Down
7 changes: 2 additions & 5 deletions test/ssh_import_auto_test.rb
Expand Up @@ -38,13 +38,10 @@

context "when no previous configurations were found" do
let(:config) { "root3" }
let(:message) do
_("No previous Linux installation found - " \
"not importing any SSH Key")
end
let(:message) { _("No previous Linux installation found") }

it "returns 'No previous Linux...' message" do
expect(subject.run).to eq("<UL>#{message}</UL>")
expect(subject.run).to eq("<UL><LI>#{message}</LI></UL>")
end
end

Expand Down

0 comments on commit d52940a

Please sign in to comment.