diff --git a/lib/jekyll-gist/gist_tag.rb b/lib/jekyll-gist/gist_tag.rb index b8742e8..2bd2273 100644 --- a/lib/jekyll-gist/gist_tag.rb +++ b/lib/jekyll-gist/gist_tag.rb @@ -25,7 +25,7 @@ def render(context) raise ArgumentError, <<~ERROR Syntax error in tag 'gist' while parsing the following markup: - #{@markup} + '{% #{raw.strip} %}' Valid syntax: {% gist user/1234567 %} diff --git a/spec/gist_tag_spec.rb b/spec/gist_tag_spec.rb index f04618c..b889220 100644 --- a/spec/gist_tag_spec.rb +++ b/spec/gist_tag_spec.rb @@ -168,7 +168,7 @@ let(:gist) { "" } it "raises an error" do - expect(-> { output }).to raise_error + expect(-> { output }).to raise_error(ArgumentError) end end end