File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
spec/integration/application Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -650,10 +650,10 @@ def with_another_agent_running(&block)
650650 . and output ( /No more routes to fileserver/ ) . to_stderr
651651 end
652652
653- it 'Updates the old cached catalog if a resource failed to apply ' do
653+ it 'preserves the old cached catalog if validation fails with the old one ' do
654654 catalog_handler = -> ( req , res ) {
655655 catalog = compile_to_catalog ( <<-MANIFEST , node )
656- exec { 'unqualified_command': path => '' }
656+ exec { 'unqualified_command': }
657657 MANIFEST
658658
659659 res . body = formatter . render ( catalog )
@@ -665,14 +665,14 @@ def with_another_agent_running(&block)
665665 expect {
666666 agent . command_line . args << '--test'
667667 agent . run
668- } . to exit_with ( 4 )
668+ } . to exit_with ( 1 )
669669 . and output ( %r{Retrieving plugin} ) . to_stdout
670- . and output ( %r{Error: Could not find command 'unqualified_command'} ) . to_stderr
670+ . and output ( %r{Validation of Exec \[ unqualified_command \] failed: 'unqualified_command' is not qualified and no path was specified } ) . to_stderr
671671 end
672672
673- # cached catalog should be updated
673+ # cached catalog should not be updated
674674 cached_catalog = "#{ File . join ( Puppet [ :client_datadir ] , 'catalog' , Puppet [ :certname ] ) } .json"
675- expect ( File ) . to be_exist ( cached_catalog )
675+ expect ( File ) . to_not be_exist ( cached_catalog )
676676 end
677677 end
678678
You can’t perform that action at this time.
0 commit comments