Commit Graph

9 Commits

Author SHA1 Message Date
voodoorai2000
338fecc7c7 Use retired trait in specs
This fixes a validation error being raised in these specs, as we were
missing some attributes that are required. Using the factory trait the
missing attributes are correctly filled out.
2019-06-27 09:21:19 +02:00
decabeza
e6af2f15fb Add new user segment all_proposals_authors 2019-05-17 17:22:29 +02:00
Julian Herrero
31ac8b7f55 Change single quotes to double quotes 2019-02-15 11:40:39 +01:00
Julian Herrero
fc69c21ebb Send newsletter emails in order
The list of emails for sending newsletters will always be ordered by
user creation date, so it will be easier to debug and to know for
which users the email has been sent.
2019-02-06 15:06:29 +01:00
Bertocq
2ecbfc76e0 Add Segment for users without supports on Budget
Created not_supported_on_current_budget at UserSegment along with model
spec scenario and translation strings.
2018-03-15 16:48:54 +01:00
María Checa
7913128520 Changed tests for UserSegments#feasible_and_undecided_investment_authors 2018-02-28 16:54:28 +01:00
Bertocq
61f015e2c2 Add administrators UserSegment
We need a user segment to have only administrators as recipients of both
newsletters and notifications
2018-02-21 23:34:20 +01:00
Bertocq
bdbb32e824 Move newsletter User scope outside UserSegments
Why:

UserSegments are not only used for Newsletters or Email downloads, but
also for internal Global Notifications. We don't want to have that scope
hardcoded inside UserSegments as users that have opted-out from the
newsletter should still be recipients of global notifications.

How:

Removing the scope from the UserSegments `all_users` method that acts as
base for all the other segments. Including that `newsletter` scope only
on the places that is relevant:
* When listing recipients for a newsletter
* When downloading a listing emails that can be newsletter recipients

Also updated relevant tests
2018-02-21 11:45:38 +01:00
María Checa
e8c797766a Added newsletter specs 2018-02-14 16:06:33 +01:00