Document tag option and clarify spec

This commit is contained in:
Douwe Maan 2017-03-13 12:17:07 -06:00
parent 6890327762
commit 6685cbeb99
2 changed files with 4 additions and 5 deletions

View File

@ -5,10 +5,9 @@ module Rouge
# Creates a new <tt>Rouge::Formatter::HTMLGitlab</tt> instance.
#
# [+linenostart+] The line number for the first line (default: 1).
def initialize(linenostart: 1, tag: nil)
@linenostart = linenostart
@line_number = linenostart
# [+tag+] The tag (language) of the lexer used to generate the formatted tokens
def initialize(tag: nil)
@line_number = 1
@tag = tag
end

View File

@ -543,7 +543,7 @@ describe 'Copy as GFM', feature: true, js: true do
end
context 'selecting multiple lines of text' do
it 'copies as a code block' do
it 'copies as a code block with the correct language' do
verify(
'.line[id="LC27"], .line[id="LC28"]',