From 688709356c2b16dfe792afe8836e63bb4643cb6c Mon Sep 17 00:00:00 2001 From: Stephan Renatus Date: Fri, 5 Feb 2016 12:01:33 +0100 Subject: [PATCH] upstart_service: add version mock for ubuntu --- test/helper.rb | 2 ++ test/unit/mock/cmd/initctl--version | 5 +++++ 2 files changed, 7 insertions(+) create mode 100644 test/unit/mock/cmd/initctl--version diff --git a/test/helper.rb b/test/helper.rb index b54bd7141..9d61344b5 100644 --- a/test/helper.rb +++ b/test/helper.rb @@ -151,6 +151,8 @@ class MockLoader 'initctl status ssh' => cmd.call('initctl-status-ssh'), # service config for upstart on ubuntu 'initctl show-config ssh' => cmd.call('initctl-show-config-ssh'), + # upstart version on ubuntu + 'initctl --version' => cmd.call('initctl--version'), # show ssh service Centos 7 'systemctl show --all sshd' => cmd.call('systemctl-show-all-sshd'), '/path/to/systemctl show --all sshd' => cmd.call('systemctl-show-all-sshd'), diff --git a/test/unit/mock/cmd/initctl--version b/test/unit/mock/cmd/initctl--version new file mode 100644 index 000000000..f74ae1a5e --- /dev/null +++ b/test/unit/mock/cmd/initctl--version @@ -0,0 +1,5 @@ +initctl (upstart 1.12.1) +Copyright (C) 2006-2014 Canonical Ltd., 2011 Scott James Remnant + +This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR +A PARTICULAR PURPOSE.