tests.test_mailbox_abstract   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 37
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 23
dl 0
loc 37
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A TestMailboxAbstract.__init__() 0 2 1
A TestMailboxAbstract.setUp() 0 14 1
1
#!/usr/bin/env python3
2
# -*- coding: utf-8 -*-
3
4
"""Module documentation goes here."""
5
6
7
import logging
8
import unittest
9
import tempfile
10
11
12
class TestMailboxAbstract(unittest.TestCase):
13
    """Class documentation goes here."""
14
    # pylint: disable=R0801
15
    class _Namespace:  # pylint: disable=R0903, R0801
16
        """Helper class for arguments."""
17
18
        def __init__(self, **kwargs):
19
            self.__dict__.update(kwargs)
20
21
    _TARGET = tempfile.mkdtemp() + '_'
22
23
    def setUp(self):
24
        logging.basicConfig(level=logging.DEBUG)
25
        self.args = self._Namespace(server='unknown.localhost',
26
                                    user='test',
27
                                    password='test',
28
                                    all=True,
29
                                    min_size=20,
30
                                    skip_download=False,
31
                                    read_only=False,
32
                                    detach=True,
33
                                    target=TestMailboxAbstract._TARGET,
34
                                    upload='tests',
35
                                    folder='tests',
36
                                    reset_cache=True)
37