Sha256: 5742ab7fb1d2e2090d245a5ec041162a7030c4ebe93ddb302ec8f16f025548a5

Contents?: true

Size: 876 Bytes

Versions: 43

Compression:

Stored size: 876 Bytes

Contents

#!/usr/bin/env rspec

require 'spec_helper'

module MCollective
  class Aggregate
    module Result
      describe Base do
        describe "#initialize" do
          it "should raise an exception if neither the ddl or the aggregate function defines a format" do
            expect{
              base = Base.new(:structure, nil, :action)
            }.to raise_error(RuntimeError, "No aggregate_format defined in ddl or aggregate function")
          end
        end

        describe "#to_s" do
          it "should raise an exception if the to_s method isn't implemented" do
            base = Base.new(:structure, :aggregate_format, :action)
            expect{
              base.to_s
            }.to raise_error(RuntimeError, "'to_s' method not implemented for result class 'MCollective::Aggregate::Result::Base'")
          end
        end
      end
    end
  end
end

Version data entries

43 entries across 43 versions & 1 rubygems

Version Path
mcollective-client-2.9.1 spec/unit/mcollective/aggregate/result/base_spec.rb
mcollective-client-2.9.0 spec/unit/mcollective/aggregate/result/base_spec.rb
mcollective-client-2.8.9 spec/unit/mcollective/aggregate/result/base_spec.rb
mcollective-client-2.8.4 spec/unit/mcollective/aggregate/result/base_spec.rb
mcollective-client-2.8.3 spec/unit/mcollective/aggregate/result/base_spec.rb
mcollective-client-2.8.2 spec/unit/mcollective/aggregate/result/base_spec.rb
mcollective-client-2.8.1 spec/unit/mcollective/aggregate/result/base_spec.rb
mcollective-client-2.8.0 spec/unit/mcollective/aggregate/result/base_spec.rb
mcollective-client-2.7.0 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.6.1 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.6.0 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.5.3 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.5.2 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.5.1 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.5.0 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.5.0.rc1 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.4.1 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.4.0 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.2.4 spec/unit/aggregate/result/base_spec.rb
mcollective-client-2.2.3 spec/unit/aggregate/result/base_spec.rb