From d3b5626af56bc9ff9ed094672ccc3c8654dfeae9 Mon Sep 17 00:00:00 2001 From: Alexander Fisher Date: Fri, 25 Nov 2016 00:14:18 +0000 Subject: [PATCH] Add unit test for zabbix_hostgroup type Really basic test to make sure type has expected parameters. --- spec/unit/puppet/type/zabbix_hostgroup_spec.rb | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 spec/unit/puppet/type/zabbix_hostgroup_spec.rb diff --git a/spec/unit/puppet/type/zabbix_hostgroup_spec.rb b/spec/unit/puppet/type/zabbix_hostgroup_spec.rb new file mode 100644 index 000000000..479d35cad --- /dev/null +++ b/spec/unit/puppet/type/zabbix_hostgroup_spec.rb @@ -0,0 +1,11 @@ +require 'spec_helper' + +describe Puppet::Type.type(:zabbix_hostgroup) do + describe 'when validating attributes' do + [:name, :zabbix_url, :zabbix_user, :zabbix_pass, :apache_use_ssl, :provider].each do |param| + it "should have a #{param} parameter" do + expect(described_class.attrtype(param)).to eq(:param) + end + end + end +end