From c2f6d1a795319eea1697f96bfd78e6d03ce2780a Mon Sep 17 00:00:00 2001 From: Ben Balter Date: Wed, 26 Apr 2017 10:45:23 -0400 Subject: [PATCH] failing test for site.social and page.seo being arrays --- spec/jekyll_seo_tag/drop_spec.rb | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/spec/jekyll_seo_tag/drop_spec.rb b/spec/jekyll_seo_tag/drop_spec.rb index f73fdc6..47a24bd 100644 --- a/spec/jekyll_seo_tag/drop_spec.rb +++ b/spec/jekyll_seo_tag/drop_spec.rb @@ -122,6 +122,14 @@ RSpec.describe Jekyll::SeoTag::Drop do end end + context "with site.social as an array" do + let(:config) { { "social" => ["a", "b"] } } + + it "uses site.social.name" do + expect(subject.name).to eql("social name") + end + end + it "uses the site title" do expect(subject.name).to eql("site title") end @@ -317,6 +325,14 @@ RSpec.describe Jekyll::SeoTag::Drop do end end + context "with seo as an array" do + let(:page_meta) { { "seo" => ["a", "b"] } } + + it "uses seo.type" do + expect(subject.type).to eql("test") + end + end + context "the homepage" do let(:page_meta) { { "permalink" => "/" } }