64029[BUGFIX] Revert behaviour of stdWrap ifEmpty
Commit message
Review
-
Code review CR +2 Done
- Benni Mack +2
- Oli Bartsch +1
- Stefan Bürk +1
- Nikita Hovratov +1
-
Verified V +2 Done
- Benni Mack +2
- Oli Bartsch +1
- Stefan Bürk +1
- Nikita Hovratov +1
- core-ci +1 CI
Issues 1
Files 2
Review log 3750
Show 1825 earlier messages
-
Sascha Egerer uploaded patch set 1 03/31/20, 11:43
-
TYPO3com voted on patch set 1 V -1 03/31/20, 11:56 Completed build in 12m 24s on Tue, 31 Mar, 11:56 AM Test Summary: 36 of 73537 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2021
-
Mathias Brodala commented on patch set 1 03/31/20, 12:07
Can we have a test which ensures this works as indentend and is never broken again? -
Sascha Egerer uploaded patch set 2 03/31/20, 12:51
-
TYPO3com voted on patch set 2 V -1 03/31/20, 13:03 Completed build in 11m 53s on Tue, 31 Mar, 01:03 PM Test Summary: 7 of 73560 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2026
-
Mathias Brodala commented on patch set 2 03/31/20, 13:27
ContentObjectRendererTest.php:1274I think we should stick to the output and not test any internal details like this. -
Sascha Egerer commented on patch set 2 03/31/20, 13:35
ContentObjectRendererTest.php:1274ReplyYou mean the output of stdWrap? I think the output depends on to many other stuff which could influence the result so i would go this way for this case. But other feedback is very welcome. -
Mathias Brodala commented on patch set 2 03/31/20, 13:44
ContentObjectRendererTest.php:1274ReplyOK, it seems I misunderstood "content" here as the output whereas it is actually the input. Still you should be able to define a full TEXT object and execute the real stdWrap function ... -
TYPO3com commented on patch set 2 03/31/20, 13:50 Completed build in 1h 10m 27s on Tue, 31 Mar, 01:50 PM Test Summary: 6 of 73561 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2026
-
Sascha Egerer commented on patch set 2 03/31/20, 13:53
ContentObjectRendererTest.php:1274ReplyAnd then also check the result of stdWrap? As said i think we should not test the result here as this will already be checked at other places. This tests only checks if the ifEmpty function is called at all due to an additional pre execution check. I'm fine width adding a 'value' to the TEXT object but this does not really change anything for this test. -
TYPO3com voted on patch set 2 V +1 03/31/20, 17:08 Completed build in 5h 26m 45s on Tue, 31 Mar, 05:08 PM Test Summary: 73074 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2026
-
TYPO3com voted on patch set 1 V +1 03/31/20, 17:20 Completed build in 5h 48m 52s on Tue, 31 Mar, 05:20 PM Test Summary: 73050 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2021
-
Susi Moog commented on patch set 2 04/01/20, 05:35
It would make sense to test the combination of pre-condition and later execution of ifEmpty to make sure that "unit" works - if you look at the history and the previous patches we try to get it right suprisingly often - for such a little function. And the original bugfix in this case was a mismatch between the pre-check and the execution. -
Sascha Egerer commented on patch set 2 04/01/20, 19:08
> Patch Set 2: > > It would make sense to test the combination of pre-condition and later execution of ifEmpty to make sure that "unit" works - if you look at the history and the previous patches we try to get it right suprisingly often - for such a little function. And the original bugfix in this case was a mismatch between the pre-check and the execution. But this is what i did in the current test, right? I do check if the condition behaves as expected and ifEmpty is called as expected. There are already unit tests for stdWrap_ifEmpty so there is no need the test the result again, right? -
Susi Moog commented on patch set 2 04/21/20, 12:10
> Patch Set 2: > > > Patch Set 2: > > > > It would make sense to test the combination of pre-condition and later execution of ifEmpty to make sure that "unit" works - if you look at the history and the previous patches we try to get it right suprisingly often - for such a little function. And the original bugfix in this case was a mismatch between the pre-check and the execution. > > But this is what i did in the current test, right? I do check if the condition behaves as expected and ifEmpty is called as expected. There are already unit tests for stdWrap_ifEmpty so there is no need the test the result again, right? Sry for not getting back to you yet, what I meant is: do we now have a test that fails and shows the original bug that was fixed / bugfixed in the last patch to make sure that does not happen again? -
Sascha Egerer commented on patch set 2 04/21/20, 12:27
> Patch Set 2: > > > Patch Set 2: > > > > > Patch Set 2: > > > > > > It would make sense to test the combination of pre-condition and later execution of ifEmpty to make sure that "unit" works - if you look at the history and the previous patches we try to get it right suprisingly often - for such a little function. And the original bugfix in this case was a mismatch between the pre-check and the execution. > > > > But this is what i did in the current test, right? I do check if the condition behaves as expected and ifEmpty is called as expected. There are already unit tests for stdWrap_ifEmpty so there is no need the test the result again, right? > > Sry for not getting back to you yet, what I meant is: do we now have a test that fails and shows the original bug that was fixed / bugfixed in the last patch to make sure that does not happen again? That should be validated by the tests I've added. -
Benni Mack updated the commit message in patch set 3 05/25/20, 18:48
-
Marc Bastian Heinrichs commented on patch set 3 V +1 05/20/21, 16:00
Patch works like expected, but from reading I don't like bool casting. I suggest to add a extra constraint !== '0' -
Benni Mack commented on patch set 3 11/05/21, 11:23
Hey Sascha, can you rebase the patch? -
Nikita Hovratov uploaded patch set 4 11/16/21, 17:53
-
Nikita Hovratov commented on patch set 4 11/16/21, 17:54
Reply
done. -
core-ci voted on patch set 4 V -1 11/16/21, 17:58 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/19366
-
Stefan Bürk commented on patch set 5 11/16/21, 18:03
Published edit on patch set 4. -
core-ci voted on patch set 5 V +1 11/16/21, 18:19 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/19367
-
Sascha Egerer commented on patch set 5 11/16/21, 19:04
Thank you Nikita for taking care
-
Benni Mack updated the commit message in patch set 6 11/18/21, 10:48
-
core-ci voted on patch set 6 V +1 11/18/21, 12:36 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/19476
-
Benni Mack wrote 11/28/21, 22:06
Removed cc Benni Mack. -
Benni Mack wrote 11/29/21, 10:21
Change destination moved from master to main -
Benni Mack updated the commit message in patch set 7 11/29/21, 14:10
-
core-ci voted on patch set 7 V +1 11/29/21, 18:46 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/20107
-
Nikita Hovratov uploaded patch set 8 01/17/22, 18:11
-
Nikita Hovratov commented on patch set 8 V +1 CR +1 01/17/22, 18:13
Reply
We just use the PHP empty function now, as the stdWrap function ifEmpty suggests.ContentObjectRendererTest.php:1274ReplyDone -
Nikita Hovratov commented on patch set 8 01/17/22, 18:18
Reply
Done -
core-ci voted on patch set 8 V -1 01/17/22, 18:30 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/22190
-
Nikita Hovratov uploaded patch set 9 01/17/22, 18:51
-
Nikita Hovratov uploaded patch set 10 01/17/22, 18:58
-
core-ci voted on patch set 9 V +1 01/17/22, 19:01 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/22193
-
core-ci voted on patch set 10 V +1 01/17/22, 19:11 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/22194
-
Nikita Hovratov voted on patch set 10 V +1 CR +1 01/17/22, 19:15
-
Oli Bartsch uploaded patch set 11 01/19/22, 22:35
-
Oli Bartsch commented on patch set 11 CR +1 01/19/22, 22:36
ContentObjectRenderer.php:1457Can this method then be deprecated / removed? It's only used in Tests and does not seem to make any sense. Both parameters are unused. Or do I just overlook sth? -
Oli Bartsch commented on patch set 11 01/19/22, 22:37
ContentObjectRenderer.php:1457ReplyForget it. Anyways not part of this patch -
core-ci voted on patch set 11 V +1 01/19/22, 22:48 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/22294
-
Oli Bartsch voted on patch set 11 V +1 01/19/22, 22:58
-
Stefan Bürk voted on patch set 11 CR +1 01/19/22, 23:05
-
Stefan Bürk voted on patch set 11 V +1 01/19/22, 23:28
-
Nikita Hovratov commented on patch set 11 V +1 CR +1 01/20/22, 08:06
ContentObjectRenderer.php:1457ReplyYes, I thought the same. Can be done in another patch. -
Benni Mack voted on patch set 11 V +2 CR +2 01/20/22, 19:16
-
Benni Mack merged patch set 12 01/20/22, 19:16