Sha256: 6776576d8bbe617c6bb8b2c0c8df8ff7f4a8f866ab25444e501089be64318e23
Contents?: true
Size: 957 Bytes
Versions: 44
Compression:
Stored size: 957 Bytes
Contents
#! /usr/bin/env ruby require 'spec_helper' test_title = 'Integration Tests for Puppet::Type::Service::Provider::Systemd' describe test_title, unless: Puppet::Util::Platform.jruby? do let(:provider_class) { Puppet::Type.type(:service).provider(:systemd) } # TODO: Unfortunately there does not seem a way to stub the executable # checks in the systemd provider because they happen at load time. it "should be considered suitable if /bin/systemctl is present", :if => File.executable?('/bin/systemctl') do expect(provider_class).to be_suitable end it "should be considered suitable if /usr/bin/systemctl is present", :if => File.executable?('/usr/bin/systemctl') do expect(provider_class).to be_suitable end it "should not be cosidered suitable if systemctl is absent", :unless => (File.executable?('/bin/systemctl') or File.executable?('/usr/bin/systemctl')) do expect(provider_class).not_to be_suitable end end
Version data entries
44 entries across 44 versions & 1 rubygems