Sha256: ee128af4d8ed54d01c98bb04e0d50182f7c41a5abd043dff149db9a334e7bfbe

Contents?: true

Size: 863 Bytes

Versions: 1

Compression:

Stored size: 863 Bytes

Contents

require 'spec_helper'
require 'puppet/face'

describe "puppet module clean" do
  subject { Puppet::Face[:module, :current] }

  describe "option validation" do
    context "without any options" do
      it "should not require any arguments" do
        Puppet::Module::Tool::Applications::Cleaner.expects(:run).once
        subject.clean
      end
    end
  end

  describe "inline documentation" do
    subject { Puppet::Face[:module, :current].get_action :clean }

    its(:summary)     { should =~ /clean.*module/im }
    its(:description) { should =~ /clean.*module/im }
    its(:returns)     { should =~ /hash/i }
    its(:examples)    { should_not be_empty }

    %w{ license copyright summary description returns examples }.each do |doc|
      context "of the" do
        its(doc.to_sym) { should_not =~ /(FIXME|REVISIT|TODO)/ }
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
puppet-2.7.9 spec/unit/face/module/clean_spec.rb