Commit d9a315a
committed
🐛 fix(config): start TOML walk from inipath
When pytest resolves config to a subdirectory (e.g. tests_integration/pytest.toml),
rootpath still points to the project root. This caused the parent pyproject.toml
to be found first, ignoring the subdirectory's pytest_env config.
Starting from inipath.parent ensures the walk begins at the directory of the
resolved config file, finding the correct pytest_env section. Falls back to
rootpath when no config file is found.1 parent c291176 commit d9a315a
2 files changed
Lines changed: 24 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
| 65 | + | |
65 | 66 | | |
66 | 67 | | |
67 | 68 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
220 | 220 | | |
221 | 221 | | |
222 | 222 | | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
223 | 232 | | |
224 | 233 | | |
225 | 234 | | |
| |||
234 | 243 | | |
235 | 244 | | |
236 | 245 | | |
237 | | - | |
238 | | - | |
239 | | - | |
240 | 246 | | |
241 | 247 | | |
242 | 248 | | |
243 | | - | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
244 | 261 | | |
245 | 262 | | |
246 | 263 | | |
| |||
251 | 268 | | |
252 | 269 | | |
253 | 270 | | |
254 | | - | |
| 271 | + | |
255 | 272 | | |
256 | 273 | | |
257 | 274 | | |
| |||
0 commit comments