Skip to content

Instantly share code, notes, and snippets.

@Miuler
Last active June 22, 2023 04:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Miuler/61926c5c7e8adc9f7d35f8e2171629d6 to your computer and use it in GitHub Desktop.
Save Miuler/61926c5c7e8adc9f7d35f8e2171629d6 to your computer and use it in GitHub Desktop.
demo-poetry-pytest
[tool.poetry]
name = "test"
version = "1.0.0"
description = "test"
authors = ["Hector Miuler Malpica Gallegos <miuler@gmail.com>"]
[tool.poetry.dependencies]
python = "^3.11"
[tool.poetry.group.test.dependencies]
pytest = "^7.3.2"
pytest-cov = "^4.1.0"
pytest-xdist = { version = "^3.3.1", extras = ["psutil"] }
[tool.pytest.ini_options]
addopts = "-n auto"
testpaths = ["tests"]
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
import unittest
class MyTestCase(unittest.TestCase):
def test_something(self):
print("Miuler")
self.assertEqual(True, True) # add assertion here
def test_something():
print("Miuler")
assert True
if __name__ == '__main__':
unittest.main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment