Hi Dob3r, could you please clarify what exactly do you mean by "one folder"? The files are sorted alphabetically in PyCharms' project tree, a custom order is not possible.
Im running my tests in PyCharm and I need to reoder tests execution, so that first I run the test that is needed to be run the first. But this test (file) is the last in the folder, so system runs it the last. I need to move the file so that it is first in the folder.
OK, I have added "a" at the beginning of the file at now it is the first in the folder. It solves my problem, thanks. But I wonder why customer order is not possible in PyCharm?
Relying on the file names to ensure the test execution order is a questionable approach, everything can fail if a new file is added to the folder or a test runner logic is changed. The "best practice" here is to utilize your test runner API for test ordering I believe. Meanwhile, changing the file order in PyCharm won't solve the problem in the first place - your test runner relies on the file names, not on the visual representation of a file tree in PyCharms' UI.
Please sign in to leave a comment.