Skip to content

Commit

Permalink
Add support for foreman_virt_who_configure
Browse files Browse the repository at this point in the history
This allows installing the core plugin and the hammer plugin.
  • Loading branch information
ekohl authored and mmoll committed Jun 16, 2018
1 parent c1b1dad commit 4a1f028
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 0 deletions.
10 changes: 10 additions & 0 deletions manifests/cli/virt_who_configure.pp
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# = Hammer Virt Who Configure plugin
#
# This installs the Virt Who Configure plugin for Hammer CLI
#
# === Parameters:
#
class foreman::cli::virt_who_configure {
foreman::cli::plugin { 'foreman_virt_who_configure':
}
}
5 changes: 5 additions & 0 deletions manifests/plugin/virt_who_configure.pp
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Installs foreman_virt_who_configure plugin
class foreman::plugin::virt_who_configure {
foreman::plugin { 'virt_who_configure':
}
}
23 changes: 23 additions & 0 deletions spec/classes/foreman_cli_virt_who_configure_spec.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
require 'spec_helper'

describe 'foreman::cli::virt_who_configure' do
context 'on redhat-7-x86_64' do
let(:facts) do
on_supported_os['redhat-7-x86_64']
end

let(:pre_condition) { 'include foreman::cli' }

it { should contain_package('tfm-rubygem-hammer_cli_foreman_virt_who_configure') }
end

context 'on debian-9-x86_64' do
let(:facts) do
on_supported_os['debian-9-x86_64']
end

let(:pre_condition) { 'include foreman::cli' }

it { should contain_package('ruby-hammer-cli-foreman-virt-who-configure') }
end
end
5 changes: 5 additions & 0 deletions spec/classes/plugin/virt_who_configure_spec.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
require 'spec_helper'

describe 'foreman::plugin::virt_who_configure' do
include_examples 'basic foreman plugin tests', 'virt_who_configure'
end

0 comments on commit 4a1f028

Please sign in to comment.