fitnesse
fitnesse copied to clipboard
RerunLastFailures file prefix stacks when using the "Rerun Failed" button
Describe the bug
When I have a page with failing tests, I get a file called RerunLastFailures_pagename
. When I then click the "Rerun failed" button, I get a file called RerunLastFailures_RerunLastFailures_pagename
. When I click the "Rerun failed" button again, I get a file with three prefixes and so on.
To Reproduce Steps to reproduce the behavior:
- Go to a page with a failing test
- Click on 'Rerun Failed'
- On the resulting page, click on 'Rerun Failed' (repeat this a few times)
- Go to file system
- See many files instead of one
Expected behavior
I would expect to only get one file RerunLastFailures_pagename
no matter how often I press the button.
Screenshots

Configuration:
- OS: MacOS 11.6
- Version of FitNesse: v20211030
- Test System: Slim
- Plugins in use: none
Additional wishes and ideas
Would it also be possible to move those files into a folder called RerunLastFailures
? This would help keep my FitNesseRoot
directory from exploding... Also, if you had a dedicated folder for these files, you could remove the prefixing (because the folder name already indicates what files they are) and that would eliminate the bug altogether.
@raducu-deaconu-visma could you take a look at addressing this bug? I expect it was introduced with your PR to include the suite name into the rerun page name. I guess adding that name is not a good idea if the name already starts with 'RerunLastFailures' :-)
Hi, The reason why we have different pages created is that we are not actually testing the same thing. If for example we have a page that fails on 5 tests initially, when we "Rerun failed" we are only targeting those 5 tests. If on this step one more test passes, we will have another rerun page, that only targets 4 tests. This is the reason behind having more than one "RerunLastFailures" prefix, as we are actually getting a result from running the "RerunLastFailures" on the previous failed tests, not on the whole suite.
Would it be possible to create those files in a subdirectory then? Currently my top-level directory gets flooded with those files, and there is no way to turn them off entirely that I know of...
@raducu-deaconu-visma I believe we should overwrite the Rerun failed page for the suite. We are still rerunning the failures from the same suite after all, only some are removed (because they now succeeded). Technically you are correct, of course. But I believe the intended usage of a re-run page is to re-try a limited set of failures from the original run. That should be the feature, so generating a new page on each re-re-run has no added value.
Ok, i will change that
@raducu-deaconu-visma any progress creating a PR for this?
I am testing this in our setup, and adjusting our setup as needed, will create a PR next week
Is there any update on the initial issue as well as putting the Rerunlastfailures files in a subfolder?
@raducu-deaconu-visma Did you ever get around to this?
Hi, I would be interested in trying to fix the issue. Could you provide more details regarding the part of the code that relates to it? Thanks.