@@ -202,27 +202,16 @@ class mod {
202
202
compile_to_catalog ( 'include mod' , node )
203
203
end
204
204
205
- it 'can apply the catalog' do
206
- Puppet [ :strict ] = :warning
207
- catalog = compile_to_catalog ( 'include mod' , node )
208
-
209
- Puppet [ :environment ] = env_name
210
- apply . command_line . args = [ '--catalog' , file_containing ( 'manifest' , catalog . to_json ) ]
211
-
212
- expect {
213
- apply . run
214
- } . to output ( %r{Notify\[ The Street 23\] /message: defined 'message' as 'The Street 23'} ) . to_stdout
215
- end
216
-
217
205
it 'can apply the catalog with no warning' do
218
- pending ( "See PUP-11751" )
219
- Puppet [ :strict ] = :warning
220
206
logs = [ ]
221
207
Puppet ::Util ::Log . with_destination ( Puppet ::Test ::LogCollector . new ( logs ) ) do
222
208
catalog = compile_to_catalog ( 'include mod' , node )
223
209
Puppet [ :environment ] = env_name
224
- apply . command_line . args = [ '--catalog' , file_containing ( 'manifest' , catalog . to_json ) ]
225
- apply . run
210
+ handler = Puppet ::Network ::FormatHandler . format ( :rich_data_json )
211
+ apply . command_line . args = [ '--catalog' , file_containing ( 'manifest' , handler . render ( catalog ) ) ]
212
+ expect {
213
+ apply . run
214
+ } . to output ( %r{Notify\[ The Street 23\] /message: defined 'message' as 'The Street 23'} ) . to_stdout
226
215
end
227
216
# expected to have no warnings
228
217
expect ( logs . select { |log | log . level == :warning } . map { |log | log . message } ) . to be_empty
0 commit comments