mirror of
https://github.com/elastic/logstash.git
synced 2025-04-25 07:07:54 -04:00
Fixed: #10781
This commit is contained in:
parent
4676aa8867
commit
2abdc3f4a2
3 changed files with 4 additions and 8 deletions
|
@ -37,7 +37,7 @@ module Bundler
|
||||||
# To be uninstalled the candidate gems need to be standalone.
|
# To be uninstalled the candidate gems need to be standalone.
|
||||||
def dependants_gems(gem_name)
|
def dependants_gems(gem_name)
|
||||||
builder = Dsl.new
|
builder = Dsl.new
|
||||||
builder.eval_gemfile("original gemfile", File.read(gemfile_path))
|
builder.eval_gemfile(::File.join(::File.dirname(gemfile_path), "original gemfile"), File.read(gemfile_path))
|
||||||
definition = builder.to_definition(lockfile_path, {})
|
definition = builder.to_definition(lockfile_path, {})
|
||||||
|
|
||||||
definition.specs
|
definition.specs
|
||||||
|
@ -66,7 +66,7 @@ module Bundler
|
||||||
|
|
||||||
gemfile = LogStash::Gemfile.new(file).load
|
gemfile = LogStash::Gemfile.new(file).load
|
||||||
gemfile.remove(gem_name)
|
gemfile.remove(gem_name)
|
||||||
builder.eval_gemfile("gemfile to changes", gemfile.generate)
|
builder.eval_gemfile(::File.join(::File.dirname(gemfile_path), "gemfile to changes"), gemfile.generate)
|
||||||
|
|
||||||
definition = builder.to_definition(lockfile_path, {})
|
definition = builder.to_definition(lockfile_path, {})
|
||||||
definition.lock(lockfile_path)
|
definition.lock(lockfile_path)
|
||||||
|
|
|
@ -36,14 +36,12 @@ shared_examples "logstash remove" do |logstash|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# Disabled because of this bug https://github.com/elastic/logstash/issues/5286
|
context "when the plugin is installed" do
|
||||||
xcontext "when the plugin is installed" do
|
|
||||||
it "successfully removes it" do
|
it "successfully removes it" do
|
||||||
result = logstash.run_command_in_path("bin/logstash-plugin install logstash-filter-qatest")
|
result = logstash.run_command_in_path("bin/logstash-plugin install logstash-filter-qatest")
|
||||||
expect(logstash).to have_installed?("logstash-filter-qatest")
|
expect(logstash).to have_installed?("logstash-filter-qatest")
|
||||||
|
|
||||||
result = logstash.run_command_in_path("bin/logstash-plugin remove logstash-filter-qatest")
|
result = logstash.run_command_in_path("bin/logstash-plugin remove logstash-filter-qatest")
|
||||||
expect(result.stdout).to match(/^Removing logstash-filter-qatest/)
|
|
||||||
expect(logstash).not_to have_installed?("logstash-filter-qatest")
|
expect(logstash).not_to have_installed?("logstash-filter-qatest")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -36,14 +36,12 @@ shared_examples "logstash uninstall" do |logstash|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# Disabled because of this bug https://github.com/elastic/logstash/issues/5286
|
context "when the plugin is installed" do
|
||||||
xcontext "when the plugin is installed" do
|
|
||||||
it "successfully uninstall it" do
|
it "successfully uninstall it" do
|
||||||
result = logstash.run_command_in_path("bin/logstash-plugin install logstash-filter-qatest")
|
result = logstash.run_command_in_path("bin/logstash-plugin install logstash-filter-qatest")
|
||||||
expect(logstash).to have_installed?("logstash-filter-qatest")
|
expect(logstash).to have_installed?("logstash-filter-qatest")
|
||||||
|
|
||||||
result = logstash.run_command_in_path("bin/logstash-plugin uninstall logstash-filter-qatest")
|
result = logstash.run_command_in_path("bin/logstash-plugin uninstall logstash-filter-qatest")
|
||||||
expect(result.stdout).to match(/^Uninstalling logstash-filter-qatest/)
|
|
||||||
expect(logstash).not_to have_installed?("logstash-filter-qatest")
|
expect(logstash).not_to have_installed?("logstash-filter-qatest")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue