Skip to content

Instantly share code, notes, and snippets.

@matutter
Created February 5, 2018 01:57
Show Gist options
  • Select an option

  • Save matutter/5ad4477fcaabbf58d2b5803f0eeb4f8b to your computer and use it in GitHub Desktop.

Select an option

Save matutter/5ad4477fcaabbf58d2b5803f0eeb4f8b to your computer and use it in GitHub Desktop.
Pocha, it looks like Mocha for python
##
# Example of using pocha, this might be good?
from pocha import describe, it
@describe('A feature')
def test_case():
@it('Should behave as expected when doing A')
def _():
assert 1 == 1
@it('Should behave as expected when doing B')
def _():
assert 1 == 1
@describe('A subcomponent')
def test_sub():
@it('Will be tested as a child test case')
def _():
assert 1 == 1
@matutter
Copy link
Copy Markdown
Author

matutter commented Feb 5, 2018

1517795747 running > pocha main.py

  A feature
    ✓ Should behave as expected when doing A
    ✓ Should behave as expected when doing B
    A subcomponent
      ✓ Will be tested as a child test case

  3 passing (0ms)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment