Project

General

Profile

« Previous | Next » 

Revision 9d43fc71

Added by Michael Moll almost 6 years ago

Fixes #19789 - fix Layout/SpaceAroundOperators cop

View differences:

test/models/concerns/hostext/operating_system_test.rb
test "available_template_kinds finds templates for a PXE host" do
os_dt = FactoryBot.create(:os_default_template,
:template_kind=> TemplateKind.friendly.find('finish'))
:template_kind => TemplateKind.friendly.find('finish'))
host = FactoryBot.create(:host, :operatingsystem => os_dt.operatingsystem)
assert_equal [os_dt.provisioning_template], host.available_template_kinds('build')
......
test "available_template_kinds finds templates for an image host" do
Foreman::Model::EC2.any_instance.stubs(:image_exists?).returns(true)
os_dt = FactoryBot.create(:os_default_template,
:template_kind=> TemplateKind.friendly.find('finish'))
:template_kind => TemplateKind.friendly.find('finish'))
host = FactoryBot.create(:host, :on_compute_resource,
:operatingsystem => os_dt.operatingsystem)
FactoryBot.create(:image, :uuid => 'abcde',

Also available in: Unified diff