Commit Graph

18 Commits

Author SHA1 Message Date
GitLab Bot 4c5468b408 Add latest changes from gitlab-org/gitlab@master 2020-06-24 15:08:50 +00:00
Thong Kuah d6b952ad3e
Add frozen_string_literal to spec/workers
Adds `# frozen_string_literal: true` to spec/workers ruby files
2019-04-01 13:35:22 -03:00
George Tsiolis 566ba126f5 Fix typos in lib 2018-11-15 12:15:43 +02:00
George Thomas 32401535b9
Improve email address parsing
If you enter the following RFC 2822 compliant address:
`John Doe <john@doe.com>`

Gitlab will attempt to send three emails:
1) John
2) Doe
3) john@doe.com

With this change given the following:
`John Doe <johndoe@example.com>`
`Jane Doe <janedoe@example.com>`

Gitlab will send emails to `johndoe@example.com` and `janedoe@example.com`
2018-07-19 12:37:59 +05:30
Lin Jen-Shin bb5f79d43e Don't include EmailHelpers manually, pick with rspec
`:mailer` is needed to pick it easily, while
`type: :mailer` is needed for picking it automatically for
tests located in spec/mailers/*_spec.rb

It's a bit complicated in spec/services/notification_service_spec.rb
but we'll leave it alone for now.
2017-08-03 21:55:48 +08:00
Robert Speicher a6ec5121f0 Correct RSpec/SingleLineHook cop offenses 2017-06-14 13:18:56 -05:00
Robert Speicher d49768296c Auto-correct `RSpec/DescribedClass` violations 2017-05-01 11:13:33 -04:00
Robert Speicher 68e6718932 Use `:empty_project` where possible in worker specs 2017-03-27 18:45:37 -04:00
Robert Speicher 819f459b69 Only include EmailHelpers in mailer specs and specs using them 2016-12-01 12:17:33 +08:00
Lin Jen-Shin 230bae9d48 Update the other sites for reset_delivered_emails! as well 2016-10-17 07:25:20 +00:00
tiagonbotelho c90483406e refactors tests because of gitlab-test repository changes 2016-10-11 16:33:06 +01:00
Sean McGivern d0fcd13ea3 Don't log to STDOUT in specs 2016-08-19 13:08:21 +01:00
Sean McGivern e37c39a21d Fix force-push message in push emails
`after_sha` maps to the source branch, as it's the head of our compare,
so these were just the wrong way around.
2016-08-19 13:07:39 +01:00
Lin Jen-Shin d5264e8804 Simplify the name for data builder, feedback:
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/5620#note_13671791
2016-08-12 16:09:29 +08:00
Lin Jen-Shin 984367f957 Move those builders to their own namespace, feedback:
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/5620#note_13540099
2016-08-04 23:44:27 +08:00
Sean McGivern 331571e067 Fix emails on push for new and deleted branches 2016-07-21 10:53:38 +01:00
Sean McGivern 5f27e26bb4 Only generate repository push email once
The repository push email can be very expensive to generate, especially
with syntax-highlighted diffs. Instead of generating the email for each
recipient, generate one email object and reset the Message-Id and To
headers for each recipient. (Cloning would also be expensive in the case
of large emails, although probably not as bad as generating from
scratch.)
2016-05-11 09:16:01 +01:00
Stan Hu 001c8cd0ee Gracefully handle SMTP user input errors (e.g. incorrect email addresses) to prevent Sidekiq retries
Closes https://github.com/gitlabhq/gitlabhq/issues/9560
2015-08-19 23:18:34 -07:00