Sha256: 7af27773c028d413290f9f1ee631a7a374d0229d4fb3541020921584d73fcd03

Contents?: true

Size: 840 Bytes

Versions: 6

Compression:

Stored size: 840 Bytes

Contents

# encoding: utf-8
require "spec_helper"

describe LogStash::Api::Commands::DefaultMetadata do
  include_context "api setup"

  let(:report_method) { :all }
  subject(:report) do
    factory = ::LogStash::Api::CommandFactory.new(LogStash::Api::Service.new(@agent))
    factory.build(:default_metadata).send(report_method)
  end

  let(:report_class) { described_class }

  describe "#plugins_stats_report" do
    let(:report_method) { :all }
    # Enforce just the structure
    it "check keys" do
      expect(report.keys).to include(
        :host,
        :version,
        :http_address,
        :id,
        :name,
        :ephemeral_id,
        :status,
        :snapshot,
        :pipeline
      )
      expect(report[:pipeline].keys).to include(
        :workers,
        :batch_size,
        :batch_delay,
      )
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
logstash-core-7.5.2-java spec/logstash/api/commands/default_metadata_spec.rb
logstash-core-7.5.1-java spec/logstash/api/commands/default_metadata_spec.rb
logstash-core-7.5.0-java spec/logstash/api/commands/default_metadata_spec.rb
logstash-core-7.4.2-java spec/logstash/api/commands/default_metadata_spec.rb
logstash-core-7.4.1-java spec/logstash/api/commands/default_metadata_spec.rb
logstash-core-7.4.0-java spec/logstash/api/commands/default_metadata_spec.rb