Commit graph

7 commits

Author SHA1 Message Date
Alejandro Rodríguez
5152cc3bfb Fix a bug where charlock_holmes was used needlessly to encode strings 2018-01-04 19:27:37 -03:00
Alejandro Rodríguez
11247ac97c Move encoding methods to the more general EncodingHelper 2017-12-28 12:32:33 -03:00
Jacob Vosmaer (GitLab)
4cfcc97544 Fix encoding bugs in Gitlab::Git::User 2017-11-23 10:48:57 +00:00
Alejandro Rodríguez
520866a0d0 Avoind unnecesary force_encoding operations
They're costly. This will also avoid some edge cases where
charlock_holmes assigns a weird encoding to a perfectly valid UTF-8
string.
2017-10-18 21:30:29 -03:00
Lin Jen-Shin
75096f958c Make sure that we have author and committer
In case we don't have it setup in ~/.gitconfig
2017-08-08 20:35:38 +08:00
Lin Jen-Shin
d831e8e1d0 Add a test to show that threshold 40 would corrupt
If we set `ENCODING_CONFIDENCE_THRESHOLD` to 40,
this test case would not pass. If we raise to 50,
this would pass.

Note that if in the future rugged didn't return
corrupt data, this would be less relevant. But still
icu recommend the threshold to be 50, we should just
stick with 50.
2017-08-08 19:10:46 +08:00
Bob Van Landuyt
e564fe971f Rename Gitlab::Git::EncodingHelper to Gitlab::EncodingHelper 2017-06-01 21:21:14 +00:00
Renamed from spec/lib/gitlab/git/encoding_helper_spec.rb (Browse further)