Last active
May 11, 2016 19:26
-
-
Save cwjohnston/524ae4fdba5ae8cd045ad4553c0e2e22 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| From 82f55f44fbff29004a350b4471b10d2d968b1a77 Mon Sep 17 00:00:00 2001 | |
| From: Cameron Johnston <cameron@rootdown.net> | |
| Date: Wed, 11 May 2016 13:03:17 -0600 | |
| Subject: [PATCH] update custom supervisor integration tests to use default | |
| logger for simplicity | |
| --- | |
| test/cookbooks/runit_test/recipes/service.rb | 3 +++ | |
| .../runit_test/templates/default/sv-supervisor_group-log-run.erb | 2 -- | |
| .../runit_test/templates/default/sv-supervisor_owner-log-run.erb | 2 -- | |
| .../templates/default/sv-supervisor_owner_and_group-log-run.erb | 2 -- | |
| test/unit/runit_service/step_into_service_spec.rb | 6 +++--- | |
| 5 files changed, 6 insertions(+), 9 deletions(-) | |
| delete mode 100644 test/cookbooks/runit_test/templates/default/sv-supervisor_group-log-run.erb | |
| delete mode 100644 test/cookbooks/runit_test/templates/default/sv-supervisor_owner-log-run.erb | |
| delete mode 100644 test/cookbooks/runit_test/templates/default/sv-supervisor_owner_and_group-log-run.erb | |
| diff --git a/test/cookbooks/runit_test/recipes/service.rb b/test/cookbooks/runit_test/recipes/service.rb | |
| index 34f875f..09cc86e 100644 | |
| --- a/test/cookbooks/runit_test/recipes/service.rb | |
| +++ b/test/cookbooks/runit_test/recipes/service.rb | |
| @@ -226,15 +226,18 @@ end | |
| runit_service 'supervisor_owner' do | |
| supervisor_owner 'floyd' | |
| + default_logger true | |
| end | |
| runit_service 'supervisor_group' do | |
| supervisor_group 'floyd' | |
| + default_logger true | |
| end | |
| runit_service 'supervisor_owner_and_group' do | |
| supervisor_owner 'floyd' | |
| supervisor_group 'floyd' | |
| + default_logger true | |
| end | |
| runit_service 'un-downed-service-deleted remove down' do | |
| diff --git a/test/cookbooks/runit_test/templates/default/sv-supervisor_group-log-run.erb b/test/cookbooks/runit_test/templates/default/sv-supervisor_group-log-run.erb | |
| deleted file mode 100644 | |
| index 628043f..0000000 | |
| --- a/test/cookbooks/runit_test/templates/default/sv-supervisor_group-log-run.erb | |
| +++ /dev/null | |
| @@ -1,2 +0,0 @@ | |
| -#!/bin/sh | |
| -exec svlogd -tt /var/log/yerba-matte | |
| diff --git a/test/cookbooks/runit_test/templates/default/sv-supervisor_owner-log-run.erb b/test/cookbooks/runit_test/templates/default/sv-supervisor_owner-log-run.erb | |
| deleted file mode 100644 | |
| index 628043f..0000000 | |
| --- a/test/cookbooks/runit_test/templates/default/sv-supervisor_owner-log-run.erb | |
| +++ /dev/null | |
| @@ -1,2 +0,0 @@ | |
| -#!/bin/sh | |
| -exec svlogd -tt /var/log/yerba-matte | |
| diff --git a/test/cookbooks/runit_test/templates/default/sv-supervisor_owner_and_group-log-run.erb b/test/cookbooks/runit_test/templates/default/sv-supervisor_owner_and_group-log-run.erb | |
| deleted file mode 100644 | |
| index 628043f..0000000 | |
| --- a/test/cookbooks/runit_test/templates/default/sv-supervisor_owner_and_group-log-run.erb | |
| +++ /dev/null | |
| @@ -1,2 +0,0 @@ | |
| -#!/bin/sh | |
| -exec svlogd -tt /var/log/yerba-matte | |
| diff --git a/test/unit/runit_service/step_into_service_spec.rb b/test/unit/runit_service/step_into_service_spec.rb | |
| index 739c440..56a50ba 100644 | |
| --- a/test/unit/runit_service/step_into_service_spec.rb | |
| +++ b/test/unit/runit_service/step_into_service_spec.rb | |
| @@ -301,7 +301,7 @@ describe 'runit_service' do | |
| let(:service_options) { Hash.new } | |
| let(:supervise_files) { %w(ok status control) } | |
| - it_behaves_like 'runit_service with default_logger set to false' | |
| + it_behaves_like 'runit_service with default logging' | |
| it 'Makes the supervise directory world writable' do | |
| expect(chef_run).to create_directory(::File.join(service_servicedir, 'supervise')).with(mode: '0755') | |
| @@ -327,7 +327,7 @@ describe 'runit_service' do | |
| let(:service_options) { Hash.new } | |
| let(:supervise_files) { %w(ok status control) } | |
| - it_behaves_like 'runit_service with default_logger set to false' | |
| + it_behaves_like 'runit_service with default logging' | |
| it 'Makes the supervise directory world writable' do | |
| expect(chef_run).to create_directory(::File.join(service_servicedir, 'supervise')).with(mode: '0755') | |
| @@ -353,7 +353,7 @@ describe 'runit_service' do | |
| let(:service_options) { Hash.new } | |
| let(:supervise_files) { %w(ok status control) } | |
| - it_behaves_like 'runit_service with default_logger set to false' | |
| + it_behaves_like 'runit_service with default logging' | |
| it 'Makes the supervise directory world writable' do | |
| expect(chef_run).to create_directory(::File.join(service_servicedir, 'supervise')).with(mode: '0755') | |
| -- | |
| 2.7.4 (Apple Git-66) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment