pytest for Unit Testing in Python | How to Python 2 | Python Tutorials

Publicado em: 01 Janeiro 1970
no canal de: Alfonso Gonzalez - Astrodynamics & SE Podcast
417
11

In this video we go over how to use the Python package pytest to implement unit tests using the Astrodynamics with Python repository to go over examples using the Python assert statement, approximately equal function, numpy arrays, warnings, errors, and how to use pytest from the command line by calling it directly or through the Python interpreter.

Link to Astrodynamics with Python GitHub repository: https://github.com/alfonsogonzalez/AWP
Link to LeetCode Algorithms with C++ and Python GitHub repository: https://github.com/alfonsogonzalez/algos

And as a sneak peek to next video, I show one way to utilize the classic Python if _name_ == '__main__' statement to be able to use unit test scripts differently based on if you run the script directly (when _name_ is equal to '__main__' ) vs unit tests (when _name_ does not equal '__main__', it equals the filename without the .py extension since the script is being imported)

#pytest #unittests #pythontutorials


Nesta página do site você pode assistir ao vídeo on-line pytest for Unit Testing in Python | How to Python 2 | Python Tutorials duração hora minuto segundo em boa qualidade , que foi baixado pelo usuário Alfonso Gonzalez - Astrodynamics & SE Podcast 01 Janeiro 1970, compartilhe o link com seus amigos e conhecidos, no youtube este vídeo já foi visto 417 vezes e gostou 11 espectadores. Boa visualização!