Commit Graph

13 Commits

Author SHA1 Message Date
Jan Jakes
a1632ea512 Satisfy PHPCS checks also in tests
[MAILPOET-6150]
2024-08-29 17:23:34 +02:00
Rodrigo Primo
9b56fdc688 Replace expect()->count() with verify()->arrayCount()
codeception/verify 2.1 removed support for expect()->count() so we need
to replace it with verify()->arrayCount().

[MAILPOET-5664]
2023-10-24 08:58:22 +03:00
Rodrigo Primo
afe378ba22 Replace expect()->equals() with verify()->equals()
codeception/verify 2.1 removed support for expect()->equals() so we need
to replace it with verify()->equals().

[MAILPOET-5664]
2023-10-24 08:58:22 +03:00
John Oleksowicz
c75bc388c9 Remove unnecessary cleanup code
MAILPOET-5145
2023-04-07 12:11:12 -05:00
Jan Jakes
c67c58709b Unify spacing of declare statements
[MAILPOET-2688]
2022-11-29 15:04:09 +01:00
Rostislav Wolny
a03f8f1c30 Use action scheduler's unique single action for daemon run
With the new unique parameter added in the action scheduler 3.5.0 the
as_schedule_single_action that schedules an immediate action
seems to be more convenient for the action scheduler.
We get better control over the scheduling of subsequent runs.
Note: We don't want to use the async action that is also executed immediately,
but it has the highest priority and we don't want to block actions scheduled by other plugins.
[MAILPOET-4684]
2022-10-13 14:21:43 +02:00
Rostislav Wolny
c44758b90d Refactor action scheduler deactivation into DaemonActionSchedulerRunner::init
[MAILPOET-4274]
2022-08-03 10:36:57 +02:00
Rostislav Wolny
977f9beb87 Refactor deactivation of MailPoet cron actions to run only once
[MAILPOET-4274]
2022-08-03 10:36:57 +02:00
Rostislav Wolny
2df7d2f686 Split integration tests after refactoring AS runner
[MAILPOET-4274]
2022-08-03 10:36:57 +02:00
Rostislav Wolny
d3e2bcdf34 Refactor daemon trigger and daemon run actions to extra classes
[MAILPOET-4274]
2022-08-03 10:36:57 +02:00
Rostislav Wolny
dfae17ed94 Add missing return and parameter types to action scheduler related classes
[MAILPOET-4274]
2022-08-03 10:36:57 +02:00
Rostislav Wolny
2ba1696d53 Add adaptive execution limit when daemon runs inside Action Scheduler
We use action_scheduler_maximum_execution_time_likely_to_be_exceeded filter for reading remaining execution limit
tracked in the Action Scheduler runner.
Then we use the remaining limit minus safety margin for the daemon execution.

[MAILPOET-4274]
2022-08-03 10:36:57 +02:00
Rostislav Wolny
cacb44444c Add DaemonActionSchedulerRunner integration test
[MAILPOET-4274]
2022-08-03 10:36:57 +02:00