File: test_unary_operators.py

package info (click to toggle)
restrictedpython 8.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,072 kB
  • sloc: python: 4,043; makefile: 193
file content (9 lines) | stat: -rw-r--r-- 184 bytes parent folder | download
1
2
3
4
5
6
7
8
9
from tests.helper import restricted_eval


def test_UAdd():
    assert restricted_eval('+a', {'a': 42}) == 42


def test_USub():
    assert restricted_eval('-a', {'a': 2411}) == -2411