Commit Graph

18 Commits

Author SHA1 Message Date
Douwe Maan a9fa45f09e Represent DiffRefs as proper class instead of tuple array 2016-07-06 18:50:58 -04:00
Adam Butler 8a8b5497c5 Create DiffFilter and change SystemNoteService#change_title to use Gitlab::Diff::InlineDiff 2016-05-18 11:15:10 -05:00
Robert Speicher 90a67a76d5 Always read diff_view setting from the cookie
Prior, when the user had their view set to "parallel" and then visited a
merge request's changes tab _without_ passing the `view` parameter via
query string, the view would be parallel but the `Notes` class was
always instantiated with the default value from `diff_view` ("inline"),
resulting in broken markup when the form to add a line note was
dynamically inserted.

The cookie is set whenever the view is changed, so this value should
always be up-to-date.

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/14557
2016-04-14 17:38:34 -04:00
Jacob Vosmaer 1764e1b7cb Use Gitlab::Git::DiffCollections 2016-03-03 18:38:44 +01:00
Douwe Maan fa0cbb1399 Fix specs and add a new one 2016-01-30 12:53:12 +01:00
Douwe Maan 701513dcc7 Move parallel diff logic to separate class 2016-01-20 14:53:20 +01:00
Rubén Dávila 6b9c730e91 More refactoring from last code review. #3945
* Use commit objects instead of IDs when generating diffs
* Use proper references when generating MR's source and target
* Update broken specs
2016-01-14 16:47:55 -05:00
Rubén Dávila 164c6374a7 Fix broken specs. #3945 2016-01-08 19:57:51 -05:00
Rubén Dávila 78d7c0e0d8 Fix broken specs. #3945 2016-01-08 19:05:55 -05:00
Rubén Dávila 7de90f4b53 Fix broken spec and small refactor. #3945 2015-12-30 18:42:11 -05:00
Robert Speicher 5a9ede4721 Update mock and stub syntax for specs 2015-06-22 12:13:46 +02:00
Alex Connor 3c892f3554 Disabled expansion of top/bottom blobs for new file diffs 2015-05-21 09:25:07 +02:00
Alex Lossent affd049dc4 Improve handling of large diffs
Diffs with a large number of changed lines time out (504 HTTP error) or
generate a HTML page that's so heavy web browsers struggle with it.

https://github.com/gitlabhq/gitlabhq/pull/5014 introduced limits on
commit line count so that only a safe portion is rendered. This was
later undone by code refactoring in be5b6db8, e0eb4803 and c741fcab.
This patch re-introduces a safe limit on number of lines.
2015-05-05 18:51:12 +02:00
Douwe Maan 8ed7ac9d44 Use project.commit convenience method. 2015-04-24 12:29:36 +02:00
Jeroen van Baarsen 026e988544 Even more hound fixes
Signed-off-by: Jeroen van Baarsen <jeroenvanbaarsen@gmail.com>
2015-02-12 21:00:55 +01:00
Jeroen van Baarsen 0c4a70a306 Updated rspec to rspec 3.x syntax
Signed-off-by: Jeroen van Baarsen <jeroenvanbaarsen@gmail.com>
2015-02-12 19:17:35 +01:00
Marin Jankovski 9b59570c8e Fix diff_helper spec. 2014-09-12 21:02:50 +02:00
Marin Jankovski 8ebb26fcc1 Add diff_helper spec. 2014-09-09 13:17:42 +02:00