Skip to content

Adds a custom pytest option for archiving logs and conf files#604

Open
ichristod wants to merge 1 commit into
apache:trunkfrom
ichristod:enhance-pyhttpd-archive-option
Open

Adds a custom pytest option for archiving logs and conf files#604
ichristod wants to merge 1 commit into
apache:trunkfrom
ichristod:enhance-pyhttpd-archive-option

Conversation

@ichristod
Copy link
Copy Markdown

The purpose of this PR is to enrich python test suite with the capability of log archiving.

With the current situation, httpd/test/gen/apache folder keeps logs and configurations of the last pytest execution either it was about a module or single test.
In addition, if you wanted to compare test results between two httpd versions, you would have to manually preserve the contents of the test/gen/apache/, before cleaning, building and installing a new httpd version.

With the --archive/archive-all option you only need to provide the parameter of the /path/to/archive and it handles the creation and the updates of the archiving folder structure.

I think it helps when you want to compare results across httpd versions.

@ichristod ichristod force-pushed the enhance-pyhttpd-archive-option branch 2 times, most recently from a905dff to 7ed0cab Compare April 28, 2026 13:43
@ichristod ichristod force-pushed the enhance-pyhttpd-archive-option branch from 7ed0cab to ef18980 Compare May 5, 2026 17:15
@ichristod
Copy link
Copy Markdown
Author

@icing I would appreciate a feedback on this one.

@icing
Copy link
Copy Markdown
Contributor

icing commented May 15, 2026

Since pytest can be invoked for specific tests and test names are designed for this, I do not see the need to add that into the test env itself. My opinion.

One can as well run pytest -k test_h2 and archive the test/gen directory contents where one likes.

I would therefore probably never use that option. But if people think it's useful for them, I'd not stop them.

@ichristod
Copy link
Copy Markdown
Author

I found it useful in my case mainly because if you choose to execute an entire module, test/gen keeps the configuration from the last test execution. So if you want to keep the configuration from each test, that isn’t possible.
A similar issue occurs with logs too, when you execute more than one module you end up with the logs from the last module only.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants