- Issue created by @bohart
- First commit to issue fork.
- πΊπ¦Ukraine quadrexdev Lutsk
Pushed the current state of the issue.
What was added/changed:
1. Subfolders for the Functional tests of a submodule.
2. Policy tests that extend Global tests of a submodule.
3. trait RerouteEmailPolicyTestTrait with a configureRerouteEmailPolicy method.
4. Fixed an issue with the validateMultipleEmails method in SettingsForm. The problem was with the usage of->getValue($element['#name'])
In case we're configuring a rerouting on the policy form - the $element['#name'] was like that: "config[reroute_email][container..." so $addresses variable is always null. Fixed by changing this line to
$element['#parents']
5. Added getRerouteConfiguration() method that returns reroute configuration depending on the $rerouteConfigurationStorage property (configureRerouteEmailPolicy or configureRerouteEmailGlobal)
6. Updated configureRerouteEmail() method so it executes a correct method depending on the $rerouteConfigurationStorage property + some required stuff like prefixes for post data. - Assigned to abyss
- Status changed to Needs work
about 1 year ago 1:11pm 5 January 2024 - πΊπ¦Ukraine bohart Lutsk, Ukraine
Hi @Abyss and @Quadrex,
thanks for your contributions!A few further notes:
1. Let's move RerouteEmailPolicyTestTrait into Policy folder, as it is used only there.2. policyConfigurationEditFormPath is used only in the trait.
Why do we need to declare it in 6 tests?3. overridePolicyLink is used only once.
Please move it from the class declaration to the setup method.4. Do we really need to specify strictConfigSchema now?
5. It looks like 2 usages of getRerouteConfiguration() should be updated.
(commented in MR)6. .gitlab-ci.yml updated in the wrong way. Tests are not running now.
Thanks!