pytest-dev / pytest-dev/pytest-html

How to specify report name and path in conftest instead of pass via arguments

Open
#176 6 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

question
Dominant language
Python
Stars
779
Forks
260
PR merge metrics
No merged PRs in 30d

Description

I generate folder for logs with timestamp and I want to store my html report there.
Unfortunately code which generate folder is in pytest framework so I can not know name of folder when I start my test. As the result my html report stores to root folder of my framework.

Is there a way to specify(overwrite) path where to store html report in conftest file instead of specifying it via arguments? Sorry if this is a duplicate issue, I did my best to find it but w/o success

Thanks in advance.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue does not mention any files, tests, or entry points. Start by examining how pytest-html receives the report path and how pytest conftest configuration is processed; define the supported configuration behavior and verify it with tests for timestamped output directories.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
testing-qa
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.