Update stdlib and concat to 6.1.0 both
[mirror/dsa-puppet.git] / 3rdparty / modules / stdlib / spec / functions / os_version_gte_spec.rb
index 4abfd7e..98ccc44 100644 (file)
@@ -30,4 +30,16 @@ describe 'os_version_gte' do
     it { is_expected.to run.with_params('Ubuntu', '18.04').and_return(true) }
     it { is_expected.to run.with_params('Fedora', '29').and_return(false) }
   end
+
+  context 'with invalid params' do
+    let(:facts) do
+      {
+        :operatingsystem => 'Ubuntu',
+        :operatingsystemmajrelease => '16.04',
+      }
+    end
+
+    it { is_expected.to run.with_params('123', 'abc').and_return(false) }
+    it { is_expected.to run.with_params([], 123).and_raise_error(ArgumentError) }
+  end
 end