lib/specinfra/command/gentoo/base/service.rb in specinfra-2.4.4 vs lib/specinfra/command/gentoo/base/service.rb in specinfra-2.4.5

- old
+ new

@@ -1,8 +1,8 @@ class Specinfra::Command::Gentoo::Base::Service < Specinfra::Command::Linux::Base::Service class << self def check_is_enabled(service, level=3) - regexp = "^\\s*#{service}\\s*|\\s*\\(boot\\|default\\)" + regexp = /\s*#{service}\s*\|\s*(boot|default)/ "rc-update show | grep -- #{escape(regexp)}" end def check_is_running(service) "/etc/init.d/#{escape(service)} status"