File tree Expand file tree Collapse file tree 3 files changed +5
-10
lines changed Expand file tree Collapse file tree 3 files changed +5
-10
lines changed Original file line number Diff line number Diff line change 2020 - {os: ubuntu-latest, ruby: '2.6'}
2121 - {os: ubuntu-latest, ruby: '2.7'}
2222 - {os: ubuntu-latest, ruby: '3.0'}
23- - {os: ubuntu-latest, ruby: 'jruby-9.3.9 .0'}
23+ - {os: ubuntu-latest, ruby: 'jruby-9.3.14 .0'}
2424 - {os: windows-2019, ruby: '2.5'}
2525 - {os: windows-2019, ruby: '2.6'}
2626 - {os: windows-2019, ruby: '2.7'}
Original file line number Diff line number Diff line change @@ -591,12 +591,11 @@ def perform_initial_import
591591 if file == NO_MANIFEST
592592 empty_parse_result
593593 elsif File . directory? ( file )
594- # JRuby does not properly perform Dir.glob operations with wildcards, (see PUP-11788 and https://github.com/jruby/jruby/issues/7836).
595594 # We sort the results because Dir.glob order is inconsistent in Ruby < 3 (see PUP-10115).
596- parse_results = Puppet ::FileSystem ::PathPattern . absolute ( File . join ( file , '**/*' ) ) . glob . select { | globbed_file | globbed_file . end_with? ( '.pp' ) } . sort . map do | file_to_parse |
597- parser . file = file_to_parse
598- parser . parse
599- end
595+ parse_results = Puppet ::FileSystem ::PathPattern . absolute ( File . join ( file , '**/*.pp ' ) ) . glob . sort . map do | file_to_parse |
596+ parser . file = file_to_parse
597+ parser . parse
598+ end
600599 # Use a parser type specific merger to concatenate the results
601600 Puppet ::Parser ::AST ::Hostclass . new ( '' , :code => Puppet ::Parser ::ParserFactory . code_merger . concatenate ( parse_results ) )
602601 else
Original file line number Diff line number Diff line change 11require 'spec_helper'
22require 'puppet_spec/files'
33require 'puppet/file_system'
4- require 'puppet/util'
54
65describe Puppet ::FileSystem ::PathPattern do
76 include PuppetSpec ::Files
134133 end
135134
136135 it 'globs wildcard patterns properly' do
137- # See PUP-11788 and https://github.com/jruby/jruby/issues/7836.
138- pending 'JRuby does not properly handle Dir.glob' if Puppet ::Util ::Platform . jruby?
139-
140136 dir = tmpdir ( 'globtest' )
141137 create_file_in ( dir , 'foo.pp' )
142138 create_file_in ( dir , 'foo.pp.pp' )
You can’t perform that action at this time.
0 commit comments