File: test_example_locals.py

package info (click to toggle)
pytest-check 2.7.6-1
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 480 kB
  • sloc: python: 2,220; sh: 17; makefile: 6
file content (17 lines) | stat: -rw-r--r-- 241 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
"""
Make sure locals can be viewed with -l or --showlocals
"""

from pytest_check import check


def test_ctx():
    a = 1
    with check:
        b = 2
        assert a == b

def test_check_func():
    a = 1
    b = 2
    check.equal(a, b)