summaryrefslogtreecommitdiff
path: root/spec/lib
diff options
context:
space:
mode:
authorKamil Trzcinski <ayufan@ayufan.eu>2016-10-18 11:56:48 +0200
committerKamil Trzcinski <ayufan@ayufan.eu>2016-10-18 11:56:48 +0200
commit66ff67b063f2c8d06f40625595c4208c33ffd1f1 (patch)
tree5a680f44a1c028aa323c8d7541726e7d5881aeb2 /spec/lib
parent829a708a970b31afdcda21fff072eda0c61dfd4c (diff)
parent4e6af0c3fa335d138343dce3e0216303a9b1cd79 (diff)
downloadgitlab-ce-66ff67b063f2c8d06f40625595c4208c33ffd1f1.tar.gz
Merge remote-tracking branch 'origin/master' into 22191-delete-dynamic-envs-mr
Diffstat (limited to 'spec/lib')
-rw-r--r--spec/lib/gitlab/conflict/file_spec.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/spec/lib/gitlab/conflict/file_spec.rb b/spec/lib/gitlab/conflict/file_spec.rb
index 60020487061..648d342ecf8 100644
--- a/spec/lib/gitlab/conflict/file_spec.rb
+++ b/spec/lib/gitlab/conflict/file_spec.rb
@@ -257,5 +257,16 @@ FILE
it 'includes the blob icon for the file' do
expect(conflict_file.as_json[:blob_icon]).to eq('file-text-o')
end
+
+ context 'with the full_content option passed' do
+ it 'includes the full content of the conflict' do
+ expect(conflict_file.as_json(full_content: true)).to have_key(:content)
+ end
+
+ it 'includes the detected language of the conflict file' do
+ expect(conflict_file.as_json(full_content: true)[:blob_ace_mode]).
+ to eq('ruby')
+ end
+ end
end
end