diff --git a/app/components/layout/footer_component.rb b/app/components/layout/footer_component.rb index 17dce63f0..c81d102ac 100644 --- a/app/components/layout/footer_component.rb +++ b/app/components/layout/footer_component.rb @@ -8,12 +8,10 @@ class Layout::FooterComponent < ApplicationComponent private def open_source_link - link_to(t("layouts.footer.open_source"), t("layouts.footer.open_source_url"), target: "_blank", - rel: "nofollow") + link_to(t("layouts.footer.open_source"), t("layouts.footer.open_source_url"), rel: "nofollow") end def repository_link - link_to(t("layouts.footer.consul"), t("layouts.footer.consul_url"), target: "_blank", - rel: "nofollow") + link_to(t("layouts.footer.consul"), t("layouts.footer.consul_url"), rel: "nofollow") end end diff --git a/spec/components/layout/footer_component_spec.rb b/spec/components/layout/footer_component_spec.rb new file mode 100644 index 000000000..83b509506 --- /dev/null +++ b/spec/components/layout/footer_component_spec.rb @@ -0,0 +1,13 @@ +require "rails_helper" + +describe Layout::FooterComponent do + describe "description links" do + it "generates links that open in the same tab" do + render_inline Layout::FooterComponent.new + + page.find(".info") do |info| + expect(info).not_to have_css "a[target]" + end + end + end +end