File: exceptions_test.py

package info (click to toggle)
wand 0.7.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 13,812 kB
  • sloc: python: 14,250; makefile: 113
file content (21 lines) | stat: -rw-r--r-- 755 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
from wand.exceptions import (BaseError, BaseFatalError, BaseWarning, BlobError,
                             BlobFatalError, BlobWarning, WandError,
                             WandFatalError, WandWarning)


def test_base_wand_error():
    assert issubclass(WandError, BaseError)
    assert issubclass(BlobError, BaseError)
    assert not issubclass(BlobError, WandError)


def test_base_wand_warning():
    assert issubclass(WandWarning, BaseWarning)
    assert issubclass(BlobWarning, BaseWarning)
    assert not issubclass(BlobWarning, WandWarning)


def test_base_wand_fatal_error():
    assert issubclass(WandFatalError, BaseFatalError)
    assert issubclass(BlobFatalError, BaseFatalError)
    assert not issubclass(BlobFatalError, WandFatalError)