File: helpers.py

package info (click to toggle)
crashtest 0.4.1-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 200 kB
  • sloc: python: 400; sh: 6; makefile: 3
file content (22 lines) | stat: -rw-r--r-- 383 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
from __future__ import annotations


def simple_exception() -> None:
    raise ValueError("Simple Exception")


def nested_exception() -> None:
    try:
        simple_exception()
    except ValueError:
        raise RuntimeError("Nested Exception")


def recursive_exception() -> None:
    def inner() -> None:
        outer()

    def outer() -> None:
        inner()

    inner()