Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Allow marked tests to be skipped under Windows

Aperta
#44 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
python

Direzione di ricerca

Inizia riproducendo l’esempio Windows fornito usando i marker skipif e forked, quindi esamina la issue 7327 di pytest collegata per l’interazione tra i marker. Il lavoro sarà considerato completato quando il comportamento scelto per i test forked non supportati su Windows sarà implementato e verificato rispetto allo snippet segnalato.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug enhancement help wanted

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:

  1. Actually respect skip markers.
  2. Skip any tests marked with forked when the env is not supported.
  3. Run these tests but w/o trying to sandbox them.

I think I like 1+2 most.

Lingua principale
Python
Stelle
83
Fork
29
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di pytest-dev/pytest-forked

Tutte le issue di pytest-dev/pytest-forked

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.