1 require 'spec_helper_acceptance'
3 if return_puppet_version =~ %r{^4}
4 describe 'is_a function' do
6 if 'hello world'.is_a(String) {
7 notify { 'output correct': }
10 it 'matches a string' do
11 apply_manifest(pp1, :catch_failures => true) do |r|
12 expect(r.stdout).to match(%r{Notice: output correct})
18 notify { 'output wrong': }
21 it 'does not match a integer as string' do
22 apply_manifest(pp2, :catch_failures => true) do |r|
23 expect(r.stdout).not_to match(%r{Notice: output wrong})