Passed
Push — master ( 3eeedc...f26de1 )
by Ken M.
02:03 queued 55s
created

test_solution_for_anything   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 28
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 20
dl 0
loc 28
rs 10
c 0
b 0
f 0
wmc 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A Tests.test_Basics() 0 3 2
1
import math  # noqa
2
import re  # noqa
3
import unittest
4
5
from solution_for_anything import checkio  # noqa
6
7
8
class Tests(unittest.TestCase):
9
    TESTS = {
10
        "1. Basics": [
11
            {"input": "checkio({1, 2, 3}) == {1, 2, 3}"},
12
            {"input": "checkio({}) != []"},
13
            {"input": "checkio('Hello') < 'World'"},
14
            {"input": "checkio(80) > 81"},
15
            {"input": "checkio(re) >= re"},
16
            {"input": "checkio(re) <= math"},
17
            {"input": "checkio(5) == ord"},
18
        ]
19
    }
20
21
    def test_Basics(self):
22
        for i in self.TESTS['1. Basics']:
23
            assert eval(i['input']), i['input']
24
25
26
if __name__ == "__main__":  # pragma: no cover
27
    unittest.main()
28