Commit Graph

41 Commits

Author SHA1 Message Date
Jan Lysý
d0ea442300 Fix integration tests compatibility
[MAILPOET-4001]
2022-01-13 16:58:33 +01:00
Ján Mikláš
fde25f4e67 Add new isSetupComplete API endpoint
[MAILPOET-4042]
2021-12-29 16:05:19 +01:00
Brezo Cordero
940e0884cb Update API Test
Change the return of mocked function sendConfirmationEmailOnce after rebasing the changes that refactor that function.

[MAILPOET-3813]
2021-12-15 11:51:12 +01:00
Brezo Cordero
81e0772459 Refactor MPAPI subscribeToLists to Doctrine
[MAILPOET-3820]
2021-12-15 11:51:12 +01:00
Rodrigo Primo
d39d09dd72 Remove calls to Subscriber::setError() from ConfirmationEmailMailer
This commit is part of a task to replace Paris with Doctrine in the
class ConfirmationEmailMailer. Specifically, it removes two calls to
Subscriber::setError() inside ConfirmationEmailMailer::sendConfirmationEmail().

setError() was used to define an error message that was used only in one
of the instances where sendConfirmationEmail() is called
(API::subscribeToLists()). setError() was replaced with code that throws
an exception when there is an error. Thus it was necessary to change all
the places where ConfirmationEmailMailer::sendConfirmationEmail() is
called to handle the exception.

In some cases, there are some oddities as sendConfirmationEmail() can
return false or throw an exception in case of an error and calling code
must account for both. I decided to settle with this approach as
refactoring the rest of this method to use exceptions instead of
returning false seemed outside of the scope of this task.

[MAILPOET-3815]
2021-12-13 16:03:07 +01:00
Rodrigo Primo
6c05b3eaf0 Pass SubscriberEntity to sendConfirmationEmail() and sendConfirmationEmailOnce()
This commit changes the methods sendConfirmationEmail() and
sendConfirmationEmailOnce() to accept as the first parameter an instance
of SubscriberEntity instead of the old model Subscriber. It also updates
all the places where those two methods are called.

[MAILPOET-3815]
2021-12-13 16:03:07 +01:00
Pavel Dohnal
1aa93d1b3c Add a new test for creating a custom field
[MAILPOET-3628]
2021-10-04 12:37:46 +02:00
Pavel Dohnal
04c2061c12 Move the tests to a separate file
[MAILPOET-3628]
2021-10-04 12:37:46 +02:00
Pavel Dohnal
518c33187f Move custom fields methods to a separate file
[MAILPOET-3628]
2021-10-04 12:37:46 +02:00
Jan Lysý
66a0834a37 Use CustomFieldRepository in integration APITest
[MAILPOET-3032]
2021-04-12 14:26:36 +02:00
Jan Lysý
6337c37e45 Update tests for third party API
[MAILPOET-3307]
2021-02-03 11:01:38 +01:00
Rostislav Wolny
54727ad9a2 Fix integration tests to work with updated codeception/verify
[MAILPOET-3203]
2020-10-20 13:18:43 +02:00
Pavel Dohnal
945b46d9d1 Fix double sending notifications
[MAILPOET-2864]
2020-04-30 10:33:58 +02:00
Jan Jakeš
b39dac75d6 Autofix number of newlines between methods
[MAILPOET-2715]
2020-02-19 19:12:53 +00:00
Jan Jakeš
835d8bc0af Fix PHPUnit 6 & Codeception\Verify incompatibilities
[MAILPOET-2582]
2020-01-28 20:18:39 +00:00
Jan Jakeš
2ec85eee7b Fix mock naming and strings in integration tests
[MAILPOET-1796]
2020-01-14 15:22:42 +01:00
Jan Jakeš
54549ff037 Convert variable names to camel case
[MAILPOET-1796]
2020-01-14 15:22:42 +01:00
Amine Ben hammou
43df66d162 Add public keyword to methods
[MAILPOET-2413]
2019-12-26 18:09:45 +03:00
wxa
ac9c250b55 Collect subscriber IPs for 3rd party API subscriptions [MAILPOET-2575] 2019-12-16 18:06:37 +00:00
Jan Jakeš
60889c53f4 Add Idiorm to MailPoetVendor namespace
[MAILPOET-2545]
2019-11-27 12:38:20 +00:00
Jan Jakeš
d970dda637 Replace "new SettingsController()" with fetch from DI container
[MAILPOET-2436]
2019-11-06 16:32:32 +00:00
Jan Jakeš
ade1cc4d8e Autofix alphabetically sorted use statements
[MAILPOET-2409]
2019-10-01 14:29:30 +01:00
Pavel Dohnal
c90a2e41a1 Use separate scheduler for welcome emails
[MAILPOET-2321]
2019-08-29 13:55:49 -04:00
Amine Ben hammou
1eecd65b3e Add unsubscribe token to new subscribers and newsletters 2019-07-31 16:50:44 -04:00
Pavel Dohnal
b52b943c97 Prevent sending notification twice
[MAILPOET-2131]
2019-06-20 11:01:48 -04:00
Jan Jakeš
8e33b0c025 Fix broken tests
[MAILPOET-2112]
2019-05-31 11:20:19 -04:00
Pavel Dohnal
c15c693507 Add method for creating custom fields in API
[MAILPOET-2041]
2019-05-30 13:03:33 -04:00
Pavel Dohnal
c4a086ba29 Add an option for sending admin notification
[MAILPOET-2042]
2019-05-29 09:58:18 -04:00
Pavel Dohnal
79bda9756e Return all information in getSubcriberFields response
[MAILPOET-2099]
2019-05-28 10:39:02 -04:00
Pavel Dohnal
352a4b82e7 Accept only whitelisted fields in addList API
[MAILPOET-2093]
2019-05-27 08:32:24 -04:00
Pavel Dohnal
97dc68c655 Accept only whitelisted fields in addSubscriber API
[MAILPOET-2093]
2019-05-27 08:32:24 -04:00
Pavel Dohnal
12ff88ee21 Add rule for operator spacing
[MAILPOET-2090]
2019-05-20 10:18:45 -04:00
Pavel Dohnal
5da7110eb6 Use short array syntax
[MAILPOET-2090]
2019-05-20 10:18:45 -04:00
Pavel Dohnal
b9af15e19f Enforce array trailling commas
[MAILPOET-2090]
2019-05-20 10:18:45 -04:00
Rostislav Wolny
e479aecdc0 Send confirmation email also within subscribeToLists
[MAILPOET-1992]
2019-05-06 11:13:49 -04:00
wxa
2f487fd300 Inject subscribe() action instead of calling it statically [MAILPOET-1825] 2019-02-21 09:51:53 -05:00
Ján Mikláš
9e9561e576 Add space between catch and ‘(‘
[MAILPOET-1791]
2019-02-13 08:26:27 -05:00
wxa
5bf968fbc6 Address PR review remarks [MAILPOET-1721] 2019-01-22 12:25:59 +03:00
wxa
a4ff9822ad Add WooCommerce customers list [MAILPOET-1721] 2019-01-17 21:42:57 +03:00
Rostislav Wolny
a42787d10d Refactor MP v1 API to obtain services via constructor
[MAILPOET-1637]
2018-11-15 09:03:43 +01:00
wxa
87e515b89d Move current unit tests to integration tests 2018-10-29 17:57:47 +03:00