You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the backup functionality was added, a regression was introduced that created an infinite loop in the first step of the update screens in core/update.php. This was reported in #6839. There is a fix for that there.
The upgrade tests (FilledUpgradePathTestCase, BareUpgradePathTestCase) should have also failed because of that regression, but they did not. We discovered in #6839 that those upgrade tests are being run as user 1, instead of anonymous (which is the case in a "normal" D7 upgrade when the setting update_free_access is TRUE).
In that issue I tried to find a way to make these tests run as anonymous, unsuccessfully. Rather than delaying the fix, I'm opening a separate issue to fix the tests so that they fail when they are supposed to.
Steps To Reproduce
In Backdrop 1.30.0, run the tests FilledUpgradePathTestCase and BareUpgradePathTestCase. The do not fail despite of the regression discussed above.
Expected behavior
Those tests should fail.
Additional information
Backdrop CMS version: 1.30.0
The text was updated successfully, but these errors were encountered:
What I struggled with is that it's impossible to use state or config for that, when running the upgrade test. Neither is available that early (before update_access_allowed() does its check). It's possible to not use the user-1 trick in UpgradePathTestCase::setUp(), hence running it as anonymous user. But that requires a hack to inject something into update_access_allowed() (and more tweaks in update.php), to simulate update_free_access. But even then the loop didn't occur in Simpletest.
As we can't use state or config for the upgrade tests, the only thing that seems to work is file_put_contents() - but we have to be careful, that we don't taint the actual site when running tests.
Description of the bug
When the backup functionality was added, a regression was introduced that created an infinite loop in the first step of the update screens in core/update.php. This was reported in #6839. There is a fix for that there.
The upgrade tests (
FilledUpgradePathTestCase
,BareUpgradePathTestCase
) should have also failed because of that regression, but they did not. We discovered in #6839 that those upgrade tests are being run as user 1, instead of anonymous (which is the case in a "normal" D7 upgrade when the settingupdate_free_access
is TRUE).In that issue I tried to find a way to make these tests run as anonymous, unsuccessfully. Rather than delaying the fix, I'm opening a separate issue to fix the tests so that they fail when they are supposed to.
Steps To Reproduce
In Backdrop 1.30.0, run the tests
FilledUpgradePathTestCase
andBareUpgradePathTestCase
. The do not fail despite of the regression discussed above.Expected behavior
Those tests should fail.
Additional information
The text was updated successfully, but these errors were encountered: