Skip to content

Commit

Permalink
[test] Updated remaining Logstash core test to use StringSetting
Browse files Browse the repository at this point in the history
  • Loading branch information
andsel committed Oct 29, 2024
1 parent b1f07d2 commit 8ffcede
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions logstash-core/spec/logstash/queue_factory_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@
let(:settings_array) do
[
LogStash::Setting::WritableDirectory.new("path.queue", Stud::Temporary.pathname),
LogStash::Setting::String.new("queue.type", "memory", true, ["persisted", "memory"]),
LogStash::Setting::StringSetting.new("queue.type", "memory", true, ["persisted", "memory"]),
LogStash::Setting::Bytes.new("queue.page_capacity", "8mb"),
LogStash::Setting::Bytes.new("queue.max_bytes", "64mb"),
LogStash::Setting::Numeric.new("queue.max_events", 0),
LogStash::Setting::Numeric.new("queue.checkpoint.acks", 1024),
LogStash::Setting::Numeric.new("queue.checkpoint.writes", 1024),
LogStash::Setting::Numeric.new("queue.checkpoint.interval", 1000),
LogStash::Setting::Boolean.new("queue.checkpoint.retry", false),
LogStash::Setting::String.new("pipeline.id", pipeline_id),
LogStash::Setting::StringSetting.new("pipeline.id", pipeline_id),
LogStash::Setting::PositiveInteger.new("pipeline.batch.size", 125),
LogStash::Setting::PositiveInteger.new("pipeline.workers", LogStash::Config::CpuCoreStrategy.maximum)
]
Expand Down
12 changes: 6 additions & 6 deletions logstash-core/spec/logstash/settings_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,8 @@
settings.on_post_process do
settings.set("baz", "bot")
end
settings.register(LogStash::Setting::String.new("foo", "bar"))
settings.register(LogStash::Setting::String.new("baz", "somedefault"))
settings.register(LogStash::Setting::StringSetting.new("foo", "bar"))
settings.register(LogStash::Setting::StringSetting.new("baz", "somedefault"))
settings.post_process
end

Expand Down Expand Up @@ -183,7 +183,7 @@
context "transient settings" do
subject do
settings = described_class.new
settings.register(LogStash::Setting::String.new("exist", "bonsoir"))
settings.register(LogStash::Setting::StringSetting.new("exist", "bonsoir"))
settings
end

Expand Down Expand Up @@ -237,9 +237,9 @@

subject do
settings = described_class.new
settings.register(LogStash::Setting::String.new("interpolated_env", "missing"))
settings.register(LogStash::Setting::String.new("with_dot_env", "missing"))
settings.register(LogStash::Setting::String.new("interpolated_store", "missing"))
settings.register(LogStash::Setting::StringSetting.new("interpolated_env", "missing"))
settings.register(LogStash::Setting::StringSetting.new("with_dot_env", "missing"))
settings.register(LogStash::Setting::StringSetting.new("interpolated_store", "missing"))
settings
end

Expand Down

0 comments on commit 8ffcede

Please sign in to comment.