2 posts tagged with "error"

    asserting errors in pytest

    2020-07-18

     | 

    ~6 min read

     | 

    1053 words

    Imagine a function that, under certain conditions expects to throw an error. How might we test that with Pytest? Pytest offers two…

    raising (custom) exceptions in python

    2020-06-25

     | 

    ~2 min read

     | 

    281 words

    If a Python program receives values it cannot handle, it can abort by raising an exception. Most of errors in Python are built on the…

Return to all tags