Commit 54be5f6e authored by Gary Holtz's avatar Gary Holtz

Modifying spec to show filetype

parent 1609eabc
......@@ -143,11 +143,17 @@ RSpec.describe Gitlab::Highlight do
end
describe 'highlight timeouts' do
let(:result) { described_class.highlight(file_name, content) }
let(:result) { described_class.highlight(file_name, content, language: "ruby") }
context 'when there is an attempt' do
it "increments the attempt counter" do
expect { result }.to change { highlight_attempt_total("undefined") }
it "increments the attempt counter with a defined language" do
expect { result }.to change { highlight_attempt_total("ruby") }
end
it "increments the attempt counter with an undefined language" do
expect do
described_class.highlight(file_name, content)
end.to change { highlight_attempt_total("undefined") }
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment