From 8d400982fe249c03725fbf8c82e96f7e9da449e9 Mon Sep 17 00:00:00 2001 From: Sean McGivern Date: Wed, 29 Aug 2018 10:27:38 +0100 Subject: [PATCH] Add spec to ensure MR diffs are highlighted --- spec/features/merge_request/user_sees_diff_spec.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spec/features/merge_request/user_sees_diff_spec.rb b/spec/features/merge_request/user_sees_diff_spec.rb index 0c15febe8df..0df9e4bbc1a 100644 --- a/spec/features/merge_request/user_sees_diff_spec.rb +++ b/spec/features/merge_request/user_sees_diff_spec.rb @@ -122,7 +122,7 @@ describe 'Merge request > User sees diff', :js do } CONTENT - file_name = 'xss_file.txt' + file_name = 'xss_file.rs' create_file('master', file_name, file_content) merge_request = create(:merge_request, source_project: project) @@ -133,6 +133,7 @@ describe 'Merge request > User sees diff', :js do visit diffs_project_merge_request_path(project, merge_request) expect(page).to have_text("function foo {") + expect(page).to have_css(".line[lang='rust'] .k") end end end