fat_free_crm 0.20.1 → 0.21.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of fat_free_crm might be problematic. Click here for more details.

Files changed (286) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +170 -0
  3. data/README.md +3 -6
  4. data/app/assets/config/manifest.js +3 -0
  5. data/app/helpers/accounts_helper.rb +2 -0
  6. data/app/helpers/application_helper.rb +22 -3
  7. data/app/helpers/tasks_helper.rb +1 -2
  8. data/app/models/entities/account.rb +1 -1
  9. data/app/models/entities/campaign.rb +1 -1
  10. data/app/models/entities/contact.rb +1 -1
  11. data/app/models/entities/lead.rb +1 -1
  12. data/app/models/entities/opportunity.rb +1 -1
  13. data/app/models/polymorphic/avatar.rb +1 -30
  14. data/app/models/polymorphic/task.rb +1 -0
  15. data/app/views/home/index.xls.builder +1 -0
  16. data/app/views/shared/_address.html.haml +1 -1
  17. data/config/application.rb +13 -0
  18. data/config/environments/development.rb +3 -0
  19. data/config/puma.rb +2 -2
  20. data/config/storage.yml +34 -0
  21. data/db/migrate/20100928030617_drop_openid_tables.rb +2 -1
  22. data/db/migrate/20230526211831_create_active_storage_tables.active_storage.rb +51 -0
  23. data/db/migrate/20230526212613_convert_to_active_storage.rb +91 -0
  24. data/db/schema.rb +65 -35
  25. data/db/seeds/fields.rb +7 -21
  26. data/lib/development_tasks/license.rake +10 -10
  27. data/lib/fat_free_crm/errors.rb +2 -10
  28. data/lib/fat_free_crm/exceptions.rb +1 -0
  29. data/lib/fat_free_crm/fields.rb +4 -5
  30. data/lib/fat_free_crm/gem_dependencies.rb +0 -1
  31. data/lib/fat_free_crm/i18n.rb +1 -1
  32. data/lib/fat_free_crm/version.rb +3 -3
  33. metadata +16 -279
  34. data/.docker/nginx/sites-enabled/ffcrm.conf +0 -8
  35. data/.github/workflows/brakeman-analysis.yml +0 -46
  36. data/.github/workflows/rubocop-analysis.yml +0 -40
  37. data/.github/workflows/ruby.yml +0 -52
  38. data/.gitignore +0 -39
  39. data/.rubocop.yml +0 -73
  40. data/.rubocop_todo.yml +0 -286
  41. data/.teatro.yml +0 -3
  42. data/.travis.yml +0 -60
  43. data/CONTRIBUTORS.md +0 -135
  44. data/Capfile +0 -27
  45. data/Dockerfile +0 -51
  46. data/Gemfile +0 -106
  47. data/Gemfile.lock +0 -529
  48. data/Guardfile +0 -26
  49. data/Procfile +0 -1
  50. data/SECURITY.md +0 -11
  51. data/Vagrantfile +0 -92
  52. data/custom_plan.rb +0 -11
  53. data/docker-compose.yml +0 -27
  54. data/fat_free_crm.gemspec +0 -62
  55. data/lib/tasks/.gitkeep +0 -0
  56. data/lib/tasks/.gitkeep~master +0 -0
  57. data/script/rails +0 -8
  58. data/spec/controllers/admin/groups_controller_spec.rb +0 -11
  59. data/spec/controllers/admin/users_controller_spec.rb +0 -251
  60. data/spec/controllers/applications_controller_spec.rb +0 -43
  61. data/spec/controllers/comments_controller_spec.rb +0 -195
  62. data/spec/controllers/emails_controller_spec.rb +0 -37
  63. data/spec/controllers/entities/accounts_controller_spec.rb +0 -607
  64. data/spec/controllers/entities/campaigns_controller_spec.rb +0 -645
  65. data/spec/controllers/entities/contacts_controller_spec.rb +0 -705
  66. data/spec/controllers/entities/leads_controller_spec.rb +0 -1009
  67. data/spec/controllers/entities/opportunities_controller_spec.rb +0 -904
  68. data/spec/controllers/entities_controller_spec.rb +0 -47
  69. data/spec/controllers/home_controller_spec.rb +0 -235
  70. data/spec/controllers/lists_controller_spec.rb +0 -11
  71. data/spec/controllers/tasks_controller_spec.rb +0 -517
  72. data/spec/controllers/users_controller_spec.rb +0 -375
  73. data/spec/factories/account_factories.rb +0 -40
  74. data/spec/factories/campaign_factories.rb +0 -30
  75. data/spec/factories/contact_factories.rb +0 -45
  76. data/spec/factories/field_factories.rb +0 -40
  77. data/spec/factories/lead_factories.rb +0 -36
  78. data/spec/factories/list_factories.rb +0 -13
  79. data/spec/factories/opportunity_factories.rb +0 -39
  80. data/spec/factories/sequences.rb +0 -32
  81. data/spec/factories/setting_factories.rb +0 -15
  82. data/spec/factories/shared_factories.rb +0 -70
  83. data/spec/factories/subscription_factories.rb +0 -13
  84. data/spec/factories/tag_factories.rb +0 -12
  85. data/spec/factories/task_factories.rb +0 -29
  86. data/spec/factories/user_factories.rb +0 -66
  87. data/spec/features/acceptance_helper.rb +0 -11
  88. data/spec/features/accounts_spec.rb +0 -126
  89. data/spec/features/admin/groups_spec.rb +0 -31
  90. data/spec/features/admin/users_spec.rb +0 -40
  91. data/spec/features/campaigns_spec.rb +0 -104
  92. data/spec/features/contacts_spec.rb +0 -134
  93. data/spec/features/dashboard_spec.rb +0 -67
  94. data/spec/features/devise/sign_in_spec.rb +0 -58
  95. data/spec/features/devise/sign_up_spec.rb +0 -36
  96. data/spec/features/leads_spec.rb +0 -138
  97. data/spec/features/opportunities_overview_spec.rb +0 -88
  98. data/spec/features/opportunities_spec.rb +0 -132
  99. data/spec/features/support/autocomlete_helper.rb +0 -17
  100. data/spec/features/support/browser.rb +0 -28
  101. data/spec/features/support/headless.rb +0 -19
  102. data/spec/features/support/paths.rb +0 -48
  103. data/spec/features/support/selector_helpers.rb +0 -36
  104. data/spec/features/tasks_spec.rb +0 -94
  105. data/spec/fixtures/rails.png +0 -0
  106. data/spec/helpers/accounts_helper_spec.rb +0 -73
  107. data/spec/helpers/admin/field_groups_helper_spec.rb +0 -20
  108. data/spec/helpers/admin/plugins_helper_spec.rb +0 -11
  109. data/spec/helpers/admin/settings_helper_spec.rb +0 -11
  110. data/spec/helpers/admin/users_helper_spec.rb +0 -11
  111. data/spec/helpers/application_helper_spec.rb +0 -86
  112. data/spec/helpers/authentications_helper_spec.rb +0 -16
  113. data/spec/helpers/campaigns_helper_spec.rb +0 -16
  114. data/spec/helpers/comments_helper_spec.rb +0 -16
  115. data/spec/helpers/contacts_helper_spec.rb +0 -16
  116. data/spec/helpers/emails_helper_spec.rb +0 -11
  117. data/spec/helpers/fields_helper_spec.rb +0 -12
  118. data/spec/helpers/groups_helper_spec.rb +0 -21
  119. data/spec/helpers/home_helper_spec.rb +0 -16
  120. data/spec/helpers/leads_helper_spec.rb +0 -16
  121. data/spec/helpers/lists_helper_spec.rb +0 -21
  122. data/spec/helpers/opportunities_helper_spec.rb +0 -16
  123. data/spec/helpers/passwords_helper_spec.rb +0 -16
  124. data/spec/helpers/tasks_helper_spec.rb +0 -20
  125. data/spec/helpers/users_helper_spec.rb +0 -39
  126. data/spec/lib/comment_extensions_spec.rb +0 -42
  127. data/spec/lib/core_ext/string_spec.rb +0 -23
  128. data/spec/lib/errors_spec.rb +0 -32
  129. data/spec/lib/fields_spec.rb +0 -101
  130. data/spec/lib/mail_processor/base_spec.rb +0 -169
  131. data/spec/lib/mail_processor/comment_replies_spec.rb +0 -70
  132. data/spec/lib/mail_processor/dropbox_spec.rb +0 -306
  133. data/spec/lib/mail_processor/sample_emails/dropbox.rb +0 -173
  134. data/spec/lib/permissions_spec.rb +0 -155
  135. data/spec/lib/secret_token_generator_spec.rb +0 -69
  136. data/spec/lib/view_factory_spec.rb +0 -69
  137. data/spec/mailers/devise_mailer_spec.rb +0 -35
  138. data/spec/mailers/subscription_mailer_spec.rb +0 -48
  139. data/spec/mailers/user_mailer_spec.rb +0 -115
  140. data/spec/models/entities/account_contact_spec.rb +0 -34
  141. data/spec/models/entities/account_opportunity_spec.rb +0 -34
  142. data/spec/models/entities/account_spec.rb +0 -206
  143. data/spec/models/entities/campaign_spec.rb +0 -131
  144. data/spec/models/entities/contact_opportunity_spec.rb +0 -34
  145. data/spec/models/entities/contact_spec.rb +0 -314
  146. data/spec/models/entities/lead_spec.rb +0 -102
  147. data/spec/models/entities/opportunity_spec.rb +0 -299
  148. data/spec/models/fields/custom_field_date_pair_spec.rb +0 -92
  149. data/spec/models/fields/custom_field_pair_spec.rb +0 -76
  150. data/spec/models/fields/custom_field_spec.rb +0 -129
  151. data/spec/models/fields/field_group_spec.rb +0 -29
  152. data/spec/models/fields/field_spec.rb +0 -69
  153. data/spec/models/list_spec.rb +0 -19
  154. data/spec/models/observers/entity_observer_spec.rb +0 -74
  155. data/spec/models/polymorphic/address_spec.rb +0 -34
  156. data/spec/models/polymorphic/avatar_spec.rb +0 -46
  157. data/spec/models/polymorphic/comment_spec.rb +0 -45
  158. data/spec/models/polymorphic/email_spec.rb +0 -53
  159. data/spec/models/polymorphic/task_spec.rb +0 -395
  160. data/spec/models/polymorphic/version_spec.rb +0 -241
  161. data/spec/models/setting_spec.rb +0 -77
  162. data/spec/models/users/abilities/user_ability_spec.rb +0 -70
  163. data/spec/models/users/group_spec.rb +0 -11
  164. data/spec/models/users/permission_spec.rb +0 -58
  165. data/spec/models/users/preference_spec.rb +0 -71
  166. data/spec/models/users/user_spec.rb +0 -238
  167. data/spec/routing/accounts_routing_spec.rb +0 -60
  168. data/spec/routing/admin/users_routing_spec.rb +0 -40
  169. data/spec/routing/campaigns_routing_spec.rb +0 -64
  170. data/spec/routing/comments_routing_spec.rb +0 -32
  171. data/spec/routing/contacts_routing_spec.rb +0 -60
  172. data/spec/routing/emails_routing_spec.rb +0 -40
  173. data/spec/routing/leads_routing_spec.rb +0 -88
  174. data/spec/routing/opportunities_routing_spec.rb +0 -64
  175. data/spec/routing/tasks_routing_spec.rb +0 -68
  176. data/spec/routing/users_routing_spec.rb +0 -106
  177. data/spec/shared/controllers.rb +0 -99
  178. data/spec/shared/models.rb +0 -141
  179. data/spec/spec_helper.rb +0 -117
  180. data/spec/support/assert_select.rb +0 -167
  181. data/spec/support/devise_helpers.rb +0 -28
  182. data/spec/support/feature_helpers.rb +0 -32
  183. data/spec/support/macros.rb +0 -49
  184. data/spec/support/mail_processor_mocks.rb +0 -37
  185. data/spec/support/uploaded_file.rb +0 -10
  186. data/spec/views/accounts/_edit.haml_spec.rb +0 -43
  187. data/spec/views/accounts/_new.haml_spec.rb +0 -42
  188. data/spec/views/accounts/create.js.haml_spec.rb +0 -52
  189. data/spec/views/accounts/destroy.js.haml_spec.rb +0 -34
  190. data/spec/views/accounts/edit.js.haml_spec.rb +0 -66
  191. data/spec/views/accounts/index.haml_spec.rb +0 -43
  192. data/spec/views/accounts/index.js.haml_spec.rb +0 -34
  193. data/spec/views/accounts/new.js.haml_spec.rb +0 -44
  194. data/spec/views/accounts/show.haml_spec.rb +0 -38
  195. data/spec/views/accounts/update.js.haml_spec.rb +0 -93
  196. data/spec/views/admin/field_groups/create.js.haml_spec.rb +0 -30
  197. data/spec/views/admin/field_groups/destroy.js.haml_spec.rb +0 -31
  198. data/spec/views/admin/field_groups/edit.js.haml_spec.rb +0 -24
  199. data/spec/views/admin/field_groups/new.js.haml_spec.rb +0 -25
  200. data/spec/views/admin/field_groups/update.js.haml_spec.rb +0 -29
  201. data/spec/views/admin/users/_create.haml_spec.rb +0 -23
  202. data/spec/views/admin/users/create.js.haml_spec.rb +0 -41
  203. data/spec/views/admin/users/destroy.js.haml_spec.rb +0 -47
  204. data/spec/views/admin/users/edit.js.haml_spec.rb +0 -44
  205. data/spec/views/admin/users/index.haml_spec.rb +0 -22
  206. data/spec/views/admin/users/index.js.haml_spec.rb +0 -26
  207. data/spec/views/admin/users/new.js.haml_spec.rb +0 -34
  208. data/spec/views/admin/users/reactivate.js.haml_spec.rb +0 -22
  209. data/spec/views/admin/users/show.haml_spec.rb +0 -18
  210. data/spec/views/admin/users/suspend.js.haml_spec.rb +0 -22
  211. data/spec/views/admin/users/update.js.haml_spec.rb +0 -37
  212. data/spec/views/application/auto_complete.haml_spec.rb +0 -48
  213. data/spec/views/campaigns/_edit.haml_spec.rb +0 -44
  214. data/spec/views/campaigns/_new.haml_spec.rb +0 -41
  215. data/spec/views/campaigns/create.js.haml_spec.rb +0 -49
  216. data/spec/views/campaigns/destroy.js.haml_spec.rb +0 -31
  217. data/spec/views/campaigns/edit.js.haml_spec.rb +0 -66
  218. data/spec/views/campaigns/index.haml_spec.rb +0 -37
  219. data/spec/views/campaigns/index.js.haml_spec.rb +0 -34
  220. data/spec/views/campaigns/new.js.haml_spec.rb +0 -50
  221. data/spec/views/campaigns/show.haml_spec.rb +0 -38
  222. data/spec/views/campaigns/update.js.haml_spec.rb +0 -78
  223. data/spec/views/comments/edit.js.haml_spec.rb +0 -30
  224. data/spec/views/contacts/_edit.haml_spec.rb +0 -73
  225. data/spec/views/contacts/_new.haml_spec.rb +0 -52
  226. data/spec/views/contacts/create.js.haml_spec.rb +0 -65
  227. data/spec/views/contacts/destroy.js.haml_spec.rb +0 -45
  228. data/spec/views/contacts/edit.js.haml_spec.rb +0 -74
  229. data/spec/views/contacts/index.haml_spec.rb +0 -37
  230. data/spec/views/contacts/index.js.html_spec.rb +0 -34
  231. data/spec/views/contacts/new.js.haml_spec.rb +0 -47
  232. data/spec/views/contacts/show.haml_spec.rb +0 -35
  233. data/spec/views/contacts/update.js.haml_spec.rb +0 -128
  234. data/spec/views/home/index.haml_spec.rb +0 -36
  235. data/spec/views/home/index.js.haml_spec.rb +0 -33
  236. data/spec/views/home/options.js.haml_spec.rb +0 -53
  237. data/spec/views/leads/_convert.haml_spec.rb +0 -30
  238. data/spec/views/leads/_edit.haml_spec.rb +0 -47
  239. data/spec/views/leads/_new.haml_spec.rb +0 -45
  240. data/spec/views/leads/_sidebar_show.haml_spec.rb +0 -31
  241. data/spec/views/leads/convert.js.haml_spec.rb +0 -79
  242. data/spec/views/leads/create.js.haml_spec.rb +0 -67
  243. data/spec/views/leads/destroy.js.haml_spec.rb +0 -47
  244. data/spec/views/leads/edit.js.haml_spec.rb +0 -76
  245. data/spec/views/leads/index.haml_spec.rb +0 -37
  246. data/spec/views/leads/index.js.haml_spec.rb +0 -34
  247. data/spec/views/leads/new.js.haml_spec.rb +0 -47
  248. data/spec/views/leads/promote.js.haml_spec.rb +0 -135
  249. data/spec/views/leads/reject.js.haml_spec.rb +0 -45
  250. data/spec/views/leads/show.haml_spec.rb +0 -32
  251. data/spec/views/leads/update.js.haml_spec.rb +0 -118
  252. data/spec/views/opportunities/_edit.haml_spec.rb +0 -70
  253. data/spec/views/opportunities/_new.haml_spec.rb +0 -51
  254. data/spec/views/opportunities/create.js.haml_spec.rb +0 -86
  255. data/spec/views/opportunities/destroy.js.haml_spec.rb +0 -64
  256. data/spec/views/opportunities/edit.js.haml_spec.rb +0 -75
  257. data/spec/views/opportunities/index.haml_spec.rb +0 -38
  258. data/spec/views/opportunities/index.js.haml_spec.rb +0 -35
  259. data/spec/views/opportunities/new.js.haml_spec.rb +0 -54
  260. data/spec/views/opportunities/show.haml_spec.rb +0 -35
  261. data/spec/views/opportunities/update.js.haml_spec.rb +0 -143
  262. data/spec/views/tasks/_edit.haml_spec.rb +0 -50
  263. data/spec/views/tasks/complete.js.haml_spec.rb +0 -67
  264. data/spec/views/tasks/create.js.haml_spec.rb +0 -119
  265. data/spec/views/tasks/destroy.js.haml_spec.rb +0 -57
  266. data/spec/views/tasks/edit.js.haml_spec.rb +0 -76
  267. data/spec/views/tasks/index.haml_spec.rb +0 -46
  268. data/spec/views/tasks/new.js.haml_spec.rb +0 -49
  269. data/spec/views/tasks/uncomplete.js.haml_spec.rb +0 -45
  270. data/spec/views/tasks/update.js.haml_spec.rb +0 -140
  271. data/spec/views/users/avatar.js.haml_spec.rb +0 -35
  272. data/spec/views/users/change_password.js.haml_spec.rb +0 -51
  273. data/spec/views/users/edit.js.haml_spec.rb +0 -35
  274. data/spec/views/users/password.js.haml_spec.rb +0 -36
  275. data/spec/views/users/update.js.haml_spec.rb +0 -46
  276. data/spec/views/users/upload_avatar.js.haml_spec.rb +0 -45
  277. data/vendor/gems/globby-0.1.2/LICENSE.txt +0 -20
  278. data/vendor/gems/globby-0.1.2/README.md +0 -65
  279. data/vendor/gems/globby-0.1.2/Rakefile +0 -9
  280. data/vendor/gems/globby-0.1.2/lib/globby/glob.rb +0 -90
  281. data/vendor/gems/globby-0.1.2/lib/globby/globject.rb +0 -18
  282. data/vendor/gems/globby-0.1.2/lib/globby/result.rb +0 -20
  283. data/vendor/gems/globby-0.1.2/lib/globby.rb +0 -47
  284. data/vendor/gems/globby-0.1.2/spec/gitignore_spec.rb +0 -109
  285. data/vendor/gems/globby-0.1.2/spec/globby_spec.rb +0 -93
  286. data/zeus.json +0 -22
@@ -1,173 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # Copyright (c) 2008-2013 Michael Dvorkin and contributors.
4
- #
5
- # Fat Free CRM is freely distributable under the terms of MIT license.
6
- # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php
7
- #------------------------------------------------------------------------------
8
- DROPBOX_EMAILS = {
9
- plain: <<~EMAIL,
10
- From: Aaron Assembler <aaron@example.com>
11
- To: Ben Bootloader <ben@example.com>
12
- Subject: Hi there
13
- Date: Mon, 26 May 2003 11:22:33 -0600
14
- Message-ID: <1234@local.machine.example>
15
- Content-Type: text/plain
16
-
17
- #{FFaker::Lorem.paragraph}
18
-
19
- Aaron
20
- EMAIL
21
-
22
- html: <<~EMAIL,
23
- From: Aaron Assembler <aaron@example.com>
24
- To: Ben Bootloader <ben@example.com>
25
- Subject: Hi there
26
- Date: Mon, 26 May 2003 11:22:33 -0600
27
- Message-ID: <1234@local.machine.example>
28
- Content-Type: text/html
29
-
30
- <html>
31
- <head></head>
32
- <body>
33
- <p>#{FFaker::Lorem.paragraph}</p>
34
- <p>Aaron</p>
35
- </body>
36
- </html>
37
- EMAIL
38
-
39
- first_line: <<~EMAIL,
40
- From: Aaron Assembler <aaron@example.com>
41
- To: Ben Bootloader <ben@example.com>
42
- Subject: Hi there
43
- Date: Mon, 26 May 2003 11:22:33 -0600
44
- Message-ID: <1234@local.machine.example>
45
- Content-Type: text/plain
46
-
47
- .campaign Got milk
48
- #{FFaker::Lorem.paragraph}
49
-
50
- Aaron
51
- EMAIL
52
-
53
- first_line_lead: <<~EMAIL,
54
- From: Aaron Assembler <aaron@example.com>
55
- To: Ben Bootloader <ben@example.com>
56
- Subject: Hi there
57
- Date: Mon, 26 May 2003 11:22:33 -0600
58
- Message-ID: <1234@local.machine.example>
59
- Content-Type: text/plain
60
-
61
- .lead Cindy Cluster
62
- #{FFaker::Lorem.paragraph}
63
-
64
- Aaron
65
- EMAIL
66
-
67
- first_line_contact: <<~EMAIL,
68
- From: Aaron Assembler <aaron@example.com>
69
- To: Ben Bootloader <ben@example.com>
70
- Subject: Hi there
71
- Date: Mon, 26 May 2003 11:22:33 -0600
72
- Message-ID: <1234@local.machine.example>
73
- Content-Type: text/plain
74
-
75
- .contact Cindy Cluster
76
- #{FFaker::Lorem.paragraph}
77
-
78
- Aaron
79
- EMAIL
80
-
81
- forwarded: <<~EMAIL,
82
- From: Aaron Assembler <aaron@example.com>
83
- To: dropbox@example.com
84
- Subject: Hi there
85
- Date: Mon, 26 May 2003 11:22:33 -0600
86
- Message-ID: <1234@local.machine.example>
87
- Content-Type: text/plain
88
-
89
- ---------- Forwarded message ----------
90
- From: Ben Bootloader <ben@example.com>
91
- Date: Sun, Mar 22, 2009 at 3:28 PM
92
- Subject: Fwd:
93
- To: Cindy Cluster <cindy@example.com>
94
-
95
- #{FFaker::Lorem.paragraph}
96
-
97
- Ben
98
- EMAIL
99
-
100
- multipart: <<~EMAIL
101
- From: Aaron Assembler <aaron@example.com>
102
- To: Ben Bootloader <ben@example.com>
103
- Subject: Hi there
104
- Date: Fri, 30 Mar 2012 15:04:05 +0800
105
- Message-ID: <1234@local.machine.example>
106
- Content-Type: multipart/related;
107
- boundary="_006_200DA2FF7EAFC04BAD979DB9CF293BB365151E88CLEARWATERtesta_";
108
- type="text/html"
109
-
110
- --_006_200DA2FF7EAFC04BAD979DB9CF293BB365151E88CLEARWATERtesta_
111
- Content-Type: text/html; charset="iso-8859-1"
112
- Content-Transfer-Encoding: quoted-printable
113
-
114
- <html>
115
- <head>
116
- <meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Diso-8859-=
117
- 1">
118
- <meta name=3D"Generator" content=3D"Microsoft Word 14 (filtered medium)">
119
- <!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
120
- o\:* {behavior:url(#default#VML);}
121
- w\:* {behavior:url(#default#VML);}
122
- .shape {behavior:url(#default#VML);}
123
- </style><![endif]--><style><!--
124
- /* Font Definitions */
125
- @font-face
126
- {font-family:Calibri;
127
- panose-1:2 15 5 2 2 2 4 3 2 4;}
128
- /* Style Definitions */
129
- p.MsoNormal, li.MsoNormal, div.MsoNormal
130
- {margin:0in;
131
- margin-bottom:.0001pt;
132
- font-size:11.0pt;
133
- font-family:"Calibri","sans-serif";}
134
- div.WordSection1
135
- {page:WordSection1;}
136
- --></style><!--[if gte mso 9]><xml>
137
- <o:shapedefaults v:ext=3D"edit" spidmax=3D"1026" />
138
- </xml><![endif]--><!--[if gte mso 9]><xml>
139
- <o:shapelayout v:ext=3D"edit">
140
- <o:idmap v:ext=3D"edit" data=3D"1" />
141
- </o:shapelayout></xml><![endif]-->
142
- </head>
143
- <body lang=3D"EN-US" link=3D"blue" vlink=3D"purple">
144
- <div class=3D"WordSection1">
145
- <p class=3D"MsoNormal"><span style=3D"color:#1F497D"><o:p>Hello,</o:p></spa=
146
- n></p>
147
- </div>
148
- </body>
149
- </html>
150
-
151
- --_006_200DA2FF7EAFC04BAD979DB9CF293BB365151E88CLEARWATERtesta_
152
- Content-Type: image/gif; name="image007.gif"
153
- Content-Description: image007.gif
154
- Content-Disposition: inline; filename="image007.gif"; size=633;
155
- creation-date="Fri, 30 Mar 2012 07:04:05 GMT";
156
- modification-date="Fri, 30 Mar 2012 07:04:05 GMT"
157
- Content-ID:<image007.gif@01CD0DBA.FB4A2170>
158
- Content-Transfer-Encoding: base64
159
-
160
- R0lGODlhXQASALMAAIiIiBESESIjIt3d3VVWVURFRLu7u2ZnZpmZmaqqqjM0M3d4d+7u7gABAMzM
161
- zP///yH5BAAAAAAALAAAAABdABIAAAT/8MlJ63Q2683tAAvTjdKwAFqyJBLQoGQsP0MgKGy3PuDi
162
- /4tHotHAWASN4MNRGMyeHYKAkshZGMnHQcFt3LhCr5IqhppH4IliXMGy3eRFQEQpELIS+oRR9Rgl
163
- VU4VBgmCFwkGFAxcdIshent4eZJhBi8Ulgh4QzkMd0QBElwLRCJyRA0HewqoiUsFqAIYQ6g4qKVt
164
- lHATQ55TEwQFu5wSBQEADB+iATgIWscMDC6qDwWyDAhONQUODA4KAQN8XIjjBH25b5S9mRIOL8MN
165
- LC5WanPulxOkGAIEFVJ6GATw9yCNKDaKdK1rIKJAAQkHpsRjISWDQReGHliiCG+CAGoTzAooEDVS
166
- DcJI6tj0CtPt2IOJBUtWMEgKEhYUnhq43KUvVEwKazTwfLmQTj8A92CKtCgTIyZ5F+6gCACyWEmD
167
- BU9OSkmGDlIF1GC6cAVUpiUYEkhlfCAgiLWAVEkCJXhFoUqGEwIU2QoI6qIACJIpwXoAmrQASg50
168
- G4LCQQBu3gjc+6lGwIA/KBPe1bOALkwasIj8wqoFFWKPqEA6QEKEmxqZQvTi1UxbEQebFRwkwJxh
169
- ADpMhSwQ4p2Bz9o8V84oX868ufPn0KNLn64hAgA7
170
-
171
- --_006_200DA2FF7EAFC04BAD979DB9CF293BB365151E88CLEARWATERtesta_--
172
- EMAIL
173
- }
@@ -1,155 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # Copyright (c) 2008-2013 Michael Dvorkin and contributors.
4
- #
5
- # Fat Free CRM is freely distributable under the terms of MIT license.
6
- # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php
7
- #------------------------------------------------------------------------------
8
- require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
9
-
10
- describe FatFreeCRM::Permissions do
11
- before do
12
- ActiveRecord::Base.connection.create_table(:user_with_permissions) do |t|
13
- t.string :access
14
- end
15
- class UserWithPermission < ActiveRecord::Base
16
- uses_user_permissions
17
- end
18
- end
19
- after do
20
- ActiveRecord::Base.connection.drop_table(:user_with_permissions)
21
- end
22
-
23
- describe "initialization" do
24
- it "should add 'has_many permissions' to the model" do
25
- entity = UserWithPermission.new
26
- expect(entity).to respond_to(:permissions)
27
- end
28
- it "should add scope called 'my'" do
29
- expect(UserWithPermission).to respond_to(:my)
30
- end
31
- end
32
-
33
- describe "user_ids" do
34
- before(:each) do
35
- @entity = UserWithPermission.create(access: "Shared")
36
- end
37
-
38
- it "should assign permissions to the object" do
39
- expect(@entity.permissions.size).to eq(0)
40
- @entity.user_ids = %w[1 2 3]
41
- @entity.save!
42
- expect(@entity.permissions.where(user_id: [1, 2, 3]).size).to eq(3)
43
- end
44
-
45
- it "should handle [] permissions" do
46
- @entity.user_ids = []
47
- @entity.save!
48
- expect(@entity.permissions.size).to eq(0)
49
- end
50
-
51
- it "should replace existing permissions" do
52
- @entity.permissions << create(:permission, user_id: 1, asset: @entity)
53
- @entity.permissions << create(:permission, user_id: 2, asset: @entity)
54
- @entity.user_ids = %w[2 3]
55
- @entity.save!
56
- expect(@entity.permissions.size).to eq(2)
57
- expect(@entity.permissions.where(user_id: [1]).size).to eq(0)
58
- expect(@entity.permissions.where(user_id: [2]).size).to eq(1)
59
- expect(@entity.permissions.where(user_id: [3]).size).to eq(1)
60
- end
61
- end
62
-
63
- describe "group_ids" do
64
- before(:each) do
65
- @entity = UserWithPermission.create(access: "Shared")
66
- end
67
- it "should assign permissions to the object" do
68
- expect(@entity.permissions.size).to eq(0)
69
- @entity.group_ids = %w[1 2 3]
70
- @entity.save!
71
- expect(@entity.permissions.where(group_id: [1, 2, 3]).size).to eq(3)
72
- end
73
-
74
- it "should handle [] permissions" do
75
- @entity.group_ids = []
76
- @entity.save!
77
- expect(@entity.permissions.size).to eq(0)
78
- end
79
-
80
- it "should replace existing permissions" do
81
- @entity.permissions << build(:permission, group_id: 1, user_id: nil, asset: @entity)
82
- @entity.permissions << build(:permission, group_id: 2, user_id: nil, asset: @entity)
83
- expect(@entity.permissions.size).to eq(2)
84
- @entity.group_ids = ['3']
85
- @entity.save!
86
- expect(@entity.permissions.size).to eq(1)
87
- expect(@entity.permissions.where(group_id: [1, 2]).size).to eq(0)
88
- expect(@entity.permissions.where(group_id: [3]).size).to eq(1)
89
- end
90
- end
91
-
92
- describe "access" do
93
- before(:each) do
94
- @entity = UserWithPermission.create
95
- end
96
- it "should delete all permissions if access is set to Public" do
97
- perm = create(:permission, user_id: 1, asset: @entity)
98
- expect(perm).to receive(:destroy)
99
- expect(Permission).to receive(:where).with(asset_id: @entity.id, asset_type: @entity.class.to_s).and_return([perm])
100
- @entity.update_attribute(:access, 'Public')
101
- end
102
- it "should delete all permissions if access is set to Private" do
103
- perm = create(:permission, user_id: 1, asset: @entity)
104
- expect(perm).to receive(:destroy)
105
- expect(Permission).to receive(:where).with(asset_id: @entity.id, asset_type: @entity.class.to_s).and_return([perm])
106
- @entity.update_attribute(:access, 'Private')
107
- end
108
- it "should not remove permissions if access is set to Shared" do
109
- perm = create(:permission, user_id: 1, asset: @entity)
110
- expect(perm).not_to receive(:destroy)
111
- @entity.permissions << perm
112
- expect(Permission).not_to receive(:find_all_by_asset_id)
113
- @entity.update_attribute(:access, 'Shared')
114
- expect(@entity.permissions.size).to eq(1)
115
- end
116
- end
117
-
118
- describe "save_with_model_permissions" do
119
- it "should copy permissions from original model" do
120
- entity = UserWithPermission.new
121
- model = mock_model(Account, access: "Shared", user_ids: [1, 2, 3], group_ids: [4, 5, 6])
122
- expect(entity).to receive(:access=).with("Shared")
123
- expect(entity).to receive(:user_ids=).with([1, 2, 3])
124
- expect(entity).to receive(:group_ids=).with([4, 5, 6])
125
- expect(entity).to receive(:save)
126
- entity.save_with_model_permissions(model)
127
- end
128
- end
129
-
130
- describe 'remove_permissions' do
131
- context 'with a new record' do
132
- before :each do
133
- @entity = UserWithPermission.new
134
- end
135
- it 'should have no relationships to destroy' do
136
- expect(@entity.remove_permissions).to eq []
137
- end
138
- end
139
-
140
- context 'with an existing record' do
141
- before :each do
142
- @entity = UserWithPermission.create
143
-
144
- @permission1 = Permission.create(user_id: 1, group_id: 1, asset_id: @entity.id, asset_type: 'UserWithPermission')
145
- @permission2 = Permission.create(user_id: 1, group_id: 2, asset_id: @entity.id, asset_type: 'UserWithPermission')
146
- end
147
- it 'should remove the related permissions' do
148
- current = Permission.all.count
149
-
150
- expect(@entity.remove_permissions.length).to eq 2
151
- expect(Permission.all.count).to eq(current - 2)
152
- end
153
- end
154
- end
155
- end
@@ -1,69 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # Copyright (c) 2008-2014 Michael Dvorkin and contributors.
4
- #
5
- # Fat Free CRM is freely distributable under the terms of MIT license.
6
- # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php
7
- #------------------------------------------------------------------------------
8
-
9
- require 'spec_helper'
10
- require 'fat_free_crm/secret_token_generator'
11
-
12
- describe FatFreeCRM::SecretTokenGenerator do
13
- let(:token) { 'e5a4b315c062dec4ecb40dabcde84fd6c067cb016a813702d2f4299ad16255c88ed1020bd47fb527e8e5f7052b04be1fbb8e63c043b8fb36f88d3c7d79a68681' }
14
-
15
- describe "setup!" do
16
- it "should not generate a new token if one exists" do
17
- allow(FatFreeCRM::SecretTokenGenerator).to receive(:token_exists?).and_return(true)
18
- expect(FatFreeCRM::SecretTokenGenerator).not_to receive(:new_token!)
19
- FatFreeCRM::SecretTokenGenerator.setup!
20
- end
21
-
22
- it "should generate a token if none exists" do
23
- allow(FatFreeCRM::SecretTokenGenerator).to receive(:token_exists?).and_return(false)
24
- expect(FatFreeCRM::SecretTokenGenerator).to receive(:new_token!)
25
- FatFreeCRM::SecretTokenGenerator.setup!
26
- end
27
-
28
- it "should generate a random token if not persisted" do
29
- allow(FatFreeCRM::SecretTokenGenerator).to receive(:token_exists?).and_return(false)
30
- allow(FatFreeCRM::SecretTokenGenerator).to receive(:new_token)
31
- expect(FatFreeCRM::SecretTokenGenerator).to receive(:generate_token).exactly(:twice)
32
- FatFreeCRM::SecretTokenGenerator.setup!
33
- end
34
- end
35
-
36
- describe "token_exists?" do
37
- it "should be true" do
38
- allow(Setting).to receive(:secret_token).and_return(token)
39
- expect(FatFreeCRM::SecretTokenGenerator.send(:token_exists?)).to eql(true)
40
- end
41
-
42
- it "should be false" do
43
- allow(Setting).to receive(:secret_token).and_return(nil)
44
- expect(FatFreeCRM::SecretTokenGenerator.send(:token_exists?)).to eql(false)
45
- end
46
- end
47
-
48
- describe "token" do
49
- it "should delegate to Setting" do
50
- expect(Setting).to receive(:secret_token).and_return(token)
51
- expect(FatFreeCRM::SecretTokenGenerator.send(:token)).to eql(token)
52
- end
53
- end
54
-
55
- describe "new_token!" do
56
- it "should generate and set a new token" do
57
- expect(FatFreeCRM::SecretTokenGenerator).to receive(:generate_token).and_return(token)
58
- expect(Setting).to receive(:secret_token=).with(token)
59
- FatFreeCRM::SecretTokenGenerator.send(:new_token!)
60
- end
61
- end
62
-
63
- describe "generate_token!" do
64
- it "should generate a random token" do
65
- expect(SecureRandom).to receive(:hex).with(64).and_return(token)
66
- FatFreeCRM::SecretTokenGenerator.send(:generate_token)
67
- end
68
- end
69
- end
@@ -1,69 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # Copyright (c) 2008-2013 Michael Dvorkin and contributors.
4
- #
5
- # Fat Free CRM is freely distributable under the terms of MIT license.
6
- # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php
7
- #------------------------------------------------------------------------------
8
- require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
9
- require "fat_free_crm/view_factory"
10
-
11
- describe FatFreeCRM::ViewFactory do
12
- before(:each) do
13
- FatFreeCRM::ViewFactory.send(:class_variable_set, '@@views', [])
14
- end
15
-
16
- describe "initialization" do
17
- before(:each) do
18
- @view_params = { name: 'brief', title: 'Brief View', icon: 'fa-bars', controllers: ['contacts'], actions: %w[show index] }
19
- end
20
-
21
- it "should initialize with required parameters" do
22
- view = FatFreeCRM::ViewFactory.new @view_params
23
- expect(view.name).to eq('brief')
24
- expect(view.title).to eq('Brief View')
25
- expect(view.controllers).to include('contacts')
26
- expect(view.actions).to include('show')
27
- expect(view.actions).to include('index')
28
- end
29
-
30
- it "should register view with ViewFactory" do
31
- expect(FatFreeCRM::ViewFactory.send(:class_variable_get, '@@views').size).to eq(0)
32
- FatFreeCRM::ViewFactory.new @view_params
33
- expect(FatFreeCRM::ViewFactory.send(:class_variable_get, '@@views').size).to eq(1)
34
- end
35
-
36
- it "should not register the same view twice" do
37
- FatFreeCRM::ViewFactory.new @view_params
38
- FatFreeCRM::ViewFactory.new @view_params
39
- views = FatFreeCRM::ViewFactory.send(:class_variable_get, '@@views')
40
- expect(views.size).to eq(1)
41
- end
42
- end
43
-
44
- describe "views_for" do
45
- before(:each) do
46
- @v1 = FatFreeCRM::ViewFactory.new name: 'brief', title: 'Brief View', controllers: ['contacts'], actions: %w[show index]
47
- @v2 = FatFreeCRM::ViewFactory.new name: 'long', title: 'Long View', controllers: ['contacts'], actions: ['show']
48
- @v3 = FatFreeCRM::ViewFactory.new name: 'full', title: 'Full View', controllers: ['accounts'], actions: ['show']
49
- end
50
-
51
- it "should return 'brief' view for ContactsController#index" do
52
- expect(FatFreeCRM::ViewFactory.views_for(controller: 'contacts', action: 'index')).to eq([@v1])
53
- end
54
-
55
- it "should return 'brief' and 'long' view for ContactsController#show" do
56
- views = FatFreeCRM::ViewFactory.views_for(controller: 'contacts', action: 'show')
57
- expect(views).to include(@v1)
58
- expect(views).to include(@v2)
59
- end
60
-
61
- it "should return 'full' view for AccountsController#show" do
62
- expect(FatFreeCRM::ViewFactory.views_for(controller: 'accounts', action: 'show')).to eq([@v3])
63
- end
64
-
65
- it "should return no views for TasksController#show" do
66
- expect(FatFreeCRM::ViewFactory.views_for(controller: 'tasks', action: 'show')).to eq([])
67
- end
68
- end
69
- end
@@ -1,35 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # Copyright (c) 2008-2013 Michael Dvorkin and contributors.
4
- #
5
- # Fat Free CRM is freely distributable under the terms of MIT license.
6
- # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php
7
- #------------------------------------------------------------------------------
8
- require 'spec_helper'
9
-
10
- describe DeviseMailer do
11
- describe "reset_password_instructions" do
12
- let(:user) { build(:user, email: "forgot_my_password@example.com") }
13
- let(:mail) { DeviseMailer.reset_password_instructions(user, user.reset_password_token) }
14
-
15
- before(:each) do
16
- allow(user).to receive(:reset_password_token).and_return("62fe5299b45513f9d22a2e1454f35dd43d62ba50")
17
- end
18
-
19
- it "sets fatfree as the sender" do
20
- expect(mail.from).to eql(["noreply@fatfreecrm.com"])
21
- end
22
-
23
- it "sets user 'forgot_my_password@example.com' as recipient" do
24
- expect(mail.to).to eq(["forgot_my_password@example.com"])
25
- end
26
-
27
- it "sets the subject" do
28
- expect(mail.subject).to eq("Reset password instructions")
29
- end
30
-
31
- it "includes password reset link in body" do
32
- expect(mail.body.encoded).to have_link('Change my password', href: "http://www.example.com/users/password/edit?reset_password_token=#{user.reset_password_token}")
33
- end
34
- end
35
- end
@@ -1,48 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # Copyright (c) 2008-2013 Michael Dvorkin and contributors.
4
- #
5
- # Fat Free CRM is freely distributable under the terms of MIT license.
6
- # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php
7
- #------------------------------------------------------------------------------
8
- require 'spec_helper'
9
-
10
- describe SubscriptionMailer do
11
- describe "comment notification" do
12
- let(:user) { build(:user, email: 'notify_me@example.com') }
13
- let(:campaign) { build(:campaign, user: user) }
14
- let(:account) { build(:account, user: user) }
15
- let(:commentable) { build_stubbed(:opportunity, id: 47, name: 'Opportunity name', account: account, campaign: campaign, user: user) }
16
- let(:comment) { build(:comment, commentable: commentable, user: user) }
17
- let(:mail) { SubscriptionMailer.comment_notification(user, comment) }
18
-
19
- it "sets user 'notify_me@example.com' as recipient" do
20
- expect(mail.to).to eq(["notify_me@example.com"])
21
- end
22
-
23
- it "sets the subject" do
24
- expect(mail.subject).to eq("RE: [opportunity:47] Opportunity name")
25
- end
26
-
27
- it "includes link to opportunity in body" do
28
- expect(mail.body.encoded).to match('http://www.example.com/opportunities/47')
29
- end
30
-
31
- it "uses email defined in settings as the sender" do
32
- allow(Setting).to receive(:dig).with(:email_comment_replies, :address).and_return("email_comment_reply@example.com")
33
- expect(mail.from).to eql(["email_comment_reply@example.com"])
34
- end
35
-
36
- it "should fallback to smtp from address as the sender" do
37
- allow(Setting).to receive(:dig).with(:email_comment_replies, :address).and_return("")
38
- allow(Setting).to receive(:dig).with(:smtp, :from).and_return("smtp_from@example.com")
39
- expect(mail.from).to eql(["smtp_from@example.com"])
40
- end
41
-
42
- it "should set default reply-to address if email doesn't exist" do
43
- allow(Setting).to receive(:dig).with(:email_comment_replies, :address).and_return("")
44
- allow(Setting).to receive(:dig).with(:smtp, :from).and_return("")
45
- expect(mail.from).to eql(["noreply@fatfreecrm.com"])
46
- end
47
- end
48
- end
@@ -1,115 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- # Copyright (c) 2008-2013 Michael Dvorkin and contributors.
4
- #
5
- # Fat Free CRM is freely distributable under the terms of MIT license.
6
- # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php
7
- #------------------------------------------------------------------------------
8
- require 'spec_helper'
9
-
10
- describe UserMailer do
11
- describe "assigned_entity_notification" do
12
- let(:assigner) { build(:user, first_name: "Bob", last_name: "Hope") }
13
- let(:assignee) { build(:user, email: "assignee@example.com") }
14
-
15
- context "for an account" do
16
- let(:account) { build_stubbed(:account, id: 16, name: 'Ghostbusters', user: assigner, assignee: assignee) }
17
- let(:mail) { UserMailer.assigned_entity_notification(account, assigner) }
18
-
19
- it "sets fatfree as the sender" do
20
- expect(mail.from).to eql(["noreply@fatfreecrm.com"])
21
- end
22
-
23
- it "sets user 'assignee@example.com' as recipient" do
24
- expect(mail.to).to eq(["assignee@example.com"])
25
- end
26
-
27
- it "sets the subject" do
28
- expect(mail.subject).to eq("Fat Free CRM: You have been assigned Ghostbusters Account")
29
- end
30
-
31
- it "includes the name of the person who re-assigned the lead in the body" do
32
- expect(mail.body.encoded).to match("Bob")
33
- end
34
-
35
- it "includes link to the lead in the body" do
36
- expect(mail.body.encoded).to match("http://www.example.com/accounts/16")
37
- end
38
- end
39
-
40
- context "for a contact" do
41
- let(:contact) { build_stubbed(:contact, id: 56, first_name: 'Harold', last_name: 'Ramis', user: assigner, assignee: assignee) }
42
- let(:mail) { UserMailer.assigned_entity_notification(contact, assigner) }
43
-
44
- it "sets fatfree as the sender" do
45
- expect(mail.from).to eql(["noreply@fatfreecrm.com"])
46
- end
47
-
48
- it "sets user 'assignee@example.com' as recipient" do
49
- expect(mail.to).to eq(["assignee@example.com"])
50
- end
51
-
52
- it "sets the subject" do
53
- expect(mail.subject).to eq("Fat Free CRM: You have been assigned Harold Ramis Contact")
54
- end
55
-
56
- it "includes the name of the person who re-assigned the lead in the body" do
57
- expect(mail.body.encoded).to match("Bob")
58
- end
59
-
60
- it "includes link to the lead in the body" do
61
- expect(mail.body.encoded).to match("http://www.example.com/contacts/56")
62
- end
63
- end
64
-
65
- context "for a lead" do
66
- let(:lead) { build_stubbed(:lead, id: 42, first_name: 'Bill', last_name: 'Murray', user: assigner, assignee: assignee) }
67
- let(:mail) { UserMailer.assigned_entity_notification(lead, assigner) }
68
-
69
- it "sets fatfree as the sender" do
70
- expect(mail.from).to eql(["noreply@fatfreecrm.com"])
71
- end
72
-
73
- it "sets user 'assignee@example.com' as recipient" do
74
- expect(mail.to).to eq(["assignee@example.com"])
75
- end
76
-
77
- it "sets the subject" do
78
- expect(mail.subject).to eq("Fat Free CRM: You have been assigned Bill Murray Lead")
79
- end
80
-
81
- it "includes the name of the person who re-assigned the lead in the body" do
82
- expect(mail.body.encoded).to match("Bob")
83
- end
84
-
85
- it "includes link to the lead in the body" do
86
- expect(mail.body.encoded).to match("http://www.example.com/leads/42")
87
- end
88
- end
89
-
90
- context "for an opportunity" do
91
- let(:opportunity) { create(:opportunity, id: 24, name: 'Big', user: assigner, assignee: assignee) }
92
- let(:mail) { UserMailer.assigned_entity_notification(opportunity, assigner) }
93
-
94
- it "sets fatfree as the sender" do
95
- expect(mail.from).to eql(["noreply@fatfreecrm.com"])
96
- end
97
-
98
- it "sets user 'assignee@example.com' as recipient" do
99
- expect(mail.to).to eq(["assignee@example.com"])
100
- end
101
-
102
- it "sets the subject" do
103
- expect(mail.subject).to eq("Fat Free CRM: You have been assigned Big Opportunity")
104
- end
105
-
106
- it "includes the name of the person who re-assigned the lead in the body" do
107
- expect(mail.body.encoded).to match("Bob")
108
- end
109
-
110
- it "includes link to the lead in the body" do
111
- expect(mail.body.encoded).to match("http://www.example.com/opportunities/24")
112
- end
113
- end
114
- end
115
- end