X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;f=3rdparty%2Fmodules%2Fstdlib%2Fspec%2Facceptance%2Fstrftime_spec.rb;h=4ba2c6aa6d6e1578bb448bf6f4cf5f600b0679bb;hb=6f656bd4265e3dab13b9af2bf96e9044322e9d8f;hp=38521b0065e5dc09fc86d6bf0bbf84fa5e647390;hpb=6963202b4b62c2816655ac9532521b018fdf83bd;p=mirror%2Fdsa-puppet.git diff --git a/3rdparty/modules/stdlib/spec/acceptance/strftime_spec.rb b/3rdparty/modules/stdlib/spec/acceptance/strftime_spec.rb old mode 100755 new mode 100644 index 38521b006..4ba2c6aa6 --- a/3rdparty/modules/stdlib/spec/acceptance/strftime_spec.rb +++ b/3rdparty/modules/stdlib/spec/acceptance/strftime_spec.rb @@ -1,16 +1,14 @@ -#! /usr/bin/env ruby -S rspec require 'spec_helper_acceptance' -describe 'strftime function' do +describe 'strftime function', :if => Puppet::Util::Package.versioncmp(Puppet.version, '4.8.0') < 0 do describe 'success' do - it 'gives the Century' do - pp = <<-EOS + pp = <<-DOC $o = strftime('%C') notice(inline_template('strftime is <%= @o.inspect %>')) - EOS - + DOC + it 'gives the Century' do apply_manifest(pp, :catch_failures => true) do |r| - expect(r.stdout).to match(/strftime is "20"/) + expect(r.stdout).to match(%r{strftime is "20"}) end end it 'takes a timezone argument'