Commit Graph

60 Commits

Author SHA1 Message Date
Rodrigo Primo
4e3f540bc1 Use WP 6.2 when running the acceptance tests
Just bumping the WP version used in the acceptance tests to the latest
version.

[MAILPOET-5075]
2023-04-25 14:24:11 -03:00
John Oleksowicz
18b953e68c Add tmpfs mount for faster MySQLing
MAILPOET-5145
2023-04-07 12:11:12 -05:00
Sam Najian
398f8ffddd Accomadate the translations placement change in WP6.2
- Compatible WPCLI is installed
- Translation folder is make writable

[MAILPOET-5073]
2023-03-30 15:58:49 +02:00
alex-mailpoet
0cbe4fa9fd Add AutomateWoo opt-in acceptance test
[MAILPOET-5057]
2023-03-06 11:22:58 +01:00
Rostislav Wolny
1cee4e67e8 Print DB tables with engine and collation on test env star
[MAILPOET-4832]
2022-12-14 12:00:49 +01:00
Rostislav Wolny
1e5cfb4eaf Switch acceptance tests oldest to MYSQL 5.5
[MAILPOET-4832]
2022-12-14 12:00:49 +01:00
Rostislav Wolny
917d64a3e3 Print sql_mode when starting test environment
[MAILPOET-4887]
2022-12-12 13:59:09 +01:00
Rostislav Wolny
a3d51b2b08 Add ANSI and ONLY_FULL_GROUP_BY to sql_mode for tests environment
The default modes shipped with the mysql or mariaDB docker containers are
STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
In this commit I added ANSI, ONLY_FULL_GROUP_BY so that we are sure that we don't break compatibility with those modes
[MAILPOET-4887]
2022-12-12 13:59:09 +01:00
Jan Jakes
82aeb89854 Use strict types in tests
[MAILPOET-2688]
2022-11-29 15:04:09 +01:00
David Remer
b6a37f274c Fix Squiz.NamingConventions.ValidVariableName.MemberNotCamelCaps
[MAILPOET-4850]
2022-11-28 22:54:13 +03:00
David Remer
7db40b27b5 Fix errors automatically with phpcbf
[MAILPOET-4850]
2022-11-28 22:54:13 +03:00
Jan Lysý
fe2df00a8c Use the latest WP version as default for acceptance tests
[MAILPOET-4841]
2022-11-26 09:09:00 +01:00
Rostislav Wolny
e677169a51 Update Mysql image for integration and acceptance tests
[MAILPOET-4851]
2022-11-25 13:37:08 +01:00
Rostislav Wolny
e268eac378 Add healthcheck for mysql service in the test environment
This is replacement for custom wait scripts and also should ensure
that DB is ready before starting the wordpress serive container,
which was missing the check.
[MAILPOET-4851]
2022-11-25 13:37:08 +01:00
Jan Lysý
1de276378f Use different container names for different parallel runs
[MAILPOET-4851]
2022-11-24 15:48:43 +01:00
Rostislav Wolny
c8636aac6f Update selenium and chrome image
[MAILPOET-4848]
2022-11-24 10:34:59 +01:00
Rostislav Wolny
324c03e8b9 Print WordPress version when starting test environment
[MAILPOET-4668]
2022-11-14 17:20:43 +01:00
Jan Jakes
eca4a68fec Revert broken test fix
Reverts: https://github.com/mailpoet/mailpoet/pull/4511

[MAILPOET-4796]
2022-11-09 15:58:36 +01:00
David Remer
9a72e361b1 Fix plugin activtion for the smtp plugin
[MAILPOET-4785]
2022-11-09 12:59:29 +03:00
David Remer
9ab6ebbe0d Use always SMTP to send wp_mail
[MAILPOET-4785]
2022-11-09 12:59:29 +03:00
Rostislav Wolny
7b7c9b18b6 Fail acceptance tests with non-zero code if activation of mailpoet fails
[MALPOET-4662]
2022-09-26 09:24:05 +02:00
Rostislav Wolny
3bcb55733a Allow write to generate folder for premium plugin in tests
We run the acceptance test with WP_DEBUG to log all errors and it also causes
that we autoregenerate twig templates.
[MAILPOET-4662]
2022-09-26 09:24:05 +02:00
Rostislav Wolny
17a990c94d Fix premium plugin detection
When mounted the plugin was mounted directly to the plugin folder get_plugins() function
ignored it. We had a similar issue in the past when we were using a softlink.
Copying the plugin is a workaround that fixes the issue.
[MAILPOET-4662]
2022-09-26 09:24:05 +02:00
Rostislav Wolny
d3f31311e6 Fix exception missing doctrine annotations files in tests
We need to delete those files before we activate the plugin.
When we do it after the activation there might already be a background request and we may delete those files
during the request.
[MAILPOET-4662]
2022-09-26 09:24:05 +02:00
Rostislav Wolny
593157f702 Fix mailpoet-premium activation in nightly tests
[MAILPOET-4662]
2022-09-26 09:24:05 +02:00
Rostislav Wolny
71340f28db Update chrome in acceptance test
Updating chrome version to improve stability.
[MAILPOET-4556]
2022-09-21 14:02:45 +02:00
Rostislav Wolny
ebdeabaccf Add option to disable COT Synchronization into integration and acceptance tests
[MAILPOET-4572]
2022-09-19 11:38:03 -03:00
Rostislav Wolny
be9643515e Add option for toggle COT in integration and acceptance tests
[MAILPOET-4572]
2022-09-19 11:38:03 -03:00
Rostislav Wolny
81f3a0420a Fix activation of plugins for multisite environments
We need to provide correct --url parameter to WP CLI commands so that
in multisite environment the correct site is affected.
Otherwise the plugins might not be activated for site we run tests on.
[MAILPOET-4625]
2022-09-08 16:53:49 +02:00
Rostislav Wolny
d643928f66 Fix indentation of code for installing WooCommerce core
[MAILPOET-4566]
2022-09-08 13:02:52 +02:00
Rostislav Wolny
77dfc8602f Skip download and installation of plugins if they are not needed
In case $SKIP_PLUGINS is set to 1 we don't activate installed plugins so it makes no sense to install them as well.
In this commit we add also skipping the installation of the plugins.
[MAILPOET-4566]
2022-09-08 13:02:52 +02:00
Rostislav Wolny
8d564a52f1 Add option for skipping 3rd party plugins activation in integration tests
[MAILPOET-4566]
2022-09-08 13:02:52 +02:00
Rostislav Wolny
bb7053306a Alway print versions of active plugins in tests
[MAILPOET-4566]
2022-09-08 13:02:52 +02:00
John Oleksowicz
c9ada07ad4 Include Woo plugins for integration tests
MAILPOET-4566
2022-09-08 13:02:52 +02:00
Rostislav Wolny
3b5d737143 Use WP ClI for setting wp-config.php constants
We experienced issues with replacing constants in wp-config.php using regular expressions.
E.g. it may stop working when new WP release changes default contents of the wp-config.php
Using WP CLI seems to be more reliable way of doing it.
[MAILPOET-4511]
2022-07-29 10:33:05 +02:00
Rostislav Wolny
1e1ef12d42 Remove no longer necessary WP CLI fix from acceptance tests
This seems to be already fixed in https://core.trac.wordpress.org/ticket/25239
[MAILPOET-4511]
2022-07-29 10:33:05 +02:00
Rostislav Wolny
3d4155f6cc Fix setting wp-config.php for acceptance tests
The wp-config properties were not set correctly because there reg exp
that was used in sed was no longer matching the default value.
This was causing e.g. that errors and warnings were not caught by the acceptnace tests.
[MAILPOET-4511]
2022-07-29 10:33:05 +02:00
alex-mailpoet
1396a979f5 Fix PHPMailer on WP 5.6 in acceptance tests
[MAILPOET-4481]

Use SMTP in PHPMailer on WP 5.6 because its Docker container
has a misconfigured mail() function (no sendmail or alternative)
2022-07-27 08:50:03 +02:00
Sam Najian
b4d270c1f2 Expose test db port to local dev machine
A not very common db port number is used so that it won’t
easily conflict with other possible instances of database

MAILPOET-4468
2022-07-08 16:04:52 +02:00
Rodrigo Primo
3e76aa672a Use WP 6.0 when running the acceptance tests
Just bumping the WP version used in the acceptance tests to the latest
version.

[MAILPOET-4297]
2022-06-15 13:50:20 +02:00
David Remer
47011ddc70 tmpfs uploads/mailpoet 2022-06-08 15:25:41 +02:00
David Remer
378515bd0e Remove cache path from docker-compose
[MAILPOET-3985]
2022-06-08 15:25:41 +02:00
Sam Najian
b69b50f5d6 Enable Xdebug for integration tests
[MAILPOET-4251]
2022-05-17 14:17:26 +02:00
Sam Najian
51fe5c58d4 Switch integrationtests to run use machine on CircleCi
[MAILPOET-4251]
2022-05-17 14:17:26 +02:00
Sam Najian
4040f216ee Enable sending email for local integration tests
[MAILPOET-4251]
2022-05-17 14:17:26 +02:00
Sam Najian
393154e080 Adjust used Docker container to run integration tests
[MAILPOET-4251]
2022-05-17 14:17:26 +02:00
Oluwaseun Olorunsola
aa0ce4a092 Update circleci/mysql 5.7.27 and 8.0 to cimg/mysql
MAILPOET-4103
2022-05-12 09:02:44 +02:00
Jan Jakes
ab27eaee2d Autoformat files with prettier
[MAILPOET-4075]
2022-04-12 15:38:27 +02:00
Rostislav Wolny
d41e395a74 Remove doctrine/annotations library before we start acceptance tests
The doctrine/annotation is not present in the production build.
This change makes the acceptance tests runtime closer the production environment.
[MAILPOET-4218]
2022-04-04 16:24:15 +02:00
Jan Lysý
4ce1c4f4e6 Use WPOrgDownloader for WC blocks downloading
[MAILPOET-3937]
2022-02-10 12:35:14 +01:00