Allow marked tests to be skipped under Windows
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 35/100
- Issue 类型
- 缺陷
- 描述清晰度
- 基本清楚
- 活跃度
- 停滞
- 技术栈
- python
调研方向
首先使用 skipif 和 forked 标记复现所提供的 Windows 示例,并查看链接的 pytest issue 7327,了解标记之间的交互。对于不受 Windows 支持的 forked 测试,选定的行为已实现,并根据报告的代码片段完成验证,即可视为完成。
由索引模型根据 Issue 内容生成。
描述
Currently, if the test is marked with forked, this plugin tries to run it in a forked subprocess regardless of the current env. Also, adding a conditional skip marker does not help and manifests itself as https://github.com/pytest-dev/pytest/issues/7327.
The following snippet still runs on Windows:
@pytest.mark.skipif(IS_WINDOWS, ...)
@pytest.mark.forked
def test():
...
The workaround that I currently use is:
@pytest.mark.skipif(IS_WINDOWS, ...)
def test():
...
if not IS_WINDOWS:
test = pytest.mark.forked(test)
This could be addressed in a few ways:
- Actually respect skip markers.
- Skip any tests marked with forked when the env is not supported.
- Run these tests but w/o trying to sandbox them.
I think I like 1+2 most.
- 主要语言
- Python
- 星标
- 84
- 派生
- 30
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
pytest-dev/pytest-forked 的其他 Issue
-
`ResourceWarning`/`PytestUnraisableExceptionWarning` with version 1.7.5可能已有人在做 @janmrow 于 33 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 72/100
pytest-dev/pytest-forked#106 ·
-
难度 1/5 1 小时以内 新手友好度 62/100
pytest-dev/pytest-forked#84 ·
-
Fork per subpath未关闭
难度 4/5 3-5 天 新手友好度 35/100
pytest-dev/pytest-forked#94 ·
-
难度 4/5 3-5 天 新手友好度 30/100
pytest-dev/pytest-forked#88 · 12 条评论 ·
-
难度 4/5 3-5 天 新手友好度 35/100
pytest-dev/pytest-forked#87 · 1 个 reaction ·
查看 pytest-dev/pytest-forked 的全部 Issue
相似的 Issue
-
bug
难度 2/5 1-3 小时 新手友好度 79/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
mohitmishra786/readprism#322 ·
维护者通常 1 天内回复
-
good first issue
难度 2/5 1-3 小时 新手友好度 76/100
-
难度 1/5 1 小时以内 新手友好度 75/100
维护者通常 1 天内回复
-
API-key credentials accept a blank key: empty via the API, spaces-only via the builder's Add API key dialog可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭
难度 2/5 1-3 小时 新手友好度 77/100
Significant-Gravitas/AutoGPT#15727 ·
维护者通常 1 天内回复