summaryrefslogtreecommitdiff
path: root/spec/spec_helper.rb
diff options
context:
space:
mode:
authorBryan McLellan <btm@loftninjas.org>2017-02-08 21:40:12 -0500
committerBryan McLellan <btm@loftninjas.org>2017-02-09 07:49:03 -0500
commit12ccb8c3f0e39fa6f7360dbf15ce463b22f60f30 (patch)
tree994b5362ba835530f60e2fba52e03b983c39469a /spec/spec_helper.rb
parent31c9757faa411c22d8d9ac1995aeba702c983095 (diff)
downloadchef-12ccb8c3f0e39fa6f7360dbf15ce463b22f60f30.tar.gz
Fix functional tests for alternate user support
On Windows you need the SeAssignPrimaryTokenPrivilege right to use CreateProcessAsUser when running under a service, even if you're an Administrator. This makes these functional tests not run under Jenkins if the jenkins user does not have this right. Signed-off-by: Bryan McLellan <btm@loftninjas.org>
Diffstat (limited to 'spec/spec_helper.rb')
-rw-r--r--spec/spec_helper.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index 9fd8e935c7..2456d3d890 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -152,6 +152,7 @@ RSpec.configure do |config|
config.filter_run_excluding :windows_powershell_no_dsc_only => true unless ! windows_powershell_dsc?
config.filter_run_excluding :windows_domain_joined_only => true unless windows_domain_joined?
config.filter_run_excluding :windows_not_domain_joined_only => true if windows_domain_joined?
+ config.filter_run_excluding :windows_service_requires_assign_token => true if !STDOUT.isatty && !windows_user_right?("SeAssignPrimaryTokenPrivilege")
config.filter_run_excluding :solaris_only => true unless solaris?
config.filter_run_excluding :system_windows_service_gem_only => true unless system_windows_service_gem?
config.filter_run_excluding :unix_only => true unless unix?