Homepage
Close
Menu

Site Navigation

  • Home
  • Archive(TODO)
    • By Day
    • By Month
  • About(TODO)
  • Stats
Close
by jacobian on 2020-11-20 (UTC).

Quick pytest tip: ran some tests, got a failure, not sure what's up?

Try this: `pytest --lf --pdb`

What this means:
--lf → "run the last failing test(s)"
--pdb → "and drop into pdb when the test fails"

(see https://t.co/6IHg5Euq55 if you need help w/pdb)

— jacobian (@jacobian) November 20, 2020
pythontip
by jacobian on 2020-11-20 (UTC).

Seems like a bunch of folks found this useful! So, here are a few more pytest flags that you might also like:

--ff → "fail fast" - stop on the first failure
--nf → run only new test cases since your last run
-k something → only run tests whose name contains 'something'

— jacobian (@jacobian) November 20, 2020
pythontip

Tags

learning tutorial misc nlp rstats gan ethics research dataviz survey python tool security kaggle video thought bayesian humour tensorflow w_code bias dataset pytorch cv tip application javascript forecast swift golang rl jax julia gnn causal surey diffusion
© Copyright Philosophy 2018 Site Template by Colorlib