expose version in HTML comment
This commit is contained in:
parent
2ee2f3e6e0
commit
bdedd23bf2
|
@ -17,6 +17,7 @@ module Jekyll
|
|||
|
||||
def payload
|
||||
{
|
||||
'seo_tag' => { 'version' => VERSION },
|
||||
'page' => context.registers[:page],
|
||||
'site' => context.registers[:site].site_payload['site']
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<!-- Begin Jekyll SEO tag -->
|
||||
<!-- Begin Jekyll SEO tag v{{ seo_tag.version }} -->
|
||||
|
||||
{% if site.url %}
|
||||
{% assign seo_url = site.url | append: site.baseurl %}
|
||||
|
|
|
@ -193,4 +193,9 @@ describe Jekyll::SeoTag do
|
|||
status = HTML::Proofer.new(dest_dir, options).run
|
||||
expect(status).to eql(true)
|
||||
end
|
||||
|
||||
it 'outputs the plugin version' do
|
||||
version = Jekyll::SeoTag::VERSION
|
||||
expect(subject.render(context)).to match(/Jekyll SEO tag v#{version}/i)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue