Passed
Push — master ( 812d55...611d69 )
by torrua
02:04
created

test_button_data_extractor   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 11
dl 0
loc 21
rs 10
c 0
b 0
f 0
wmc 3
1
# -*- coding:utf-8 -*-
2
"""
3
Test for _button_data_extractor() function
4
"""
5
import os
6
import sys
7
8
sys.path.insert(0, "%s/../" % os.path.dirname(os.path.abspath(__file__)))
9
10
import pytest
11
12
from keyboa.keyboards import _button_data_extractor
13
14
15
def test_button_data_extractor():
16
    with pytest.raises(TypeError) as _:
17
        _button_data_extractor(True)
18
19
    with pytest.raises(TypeError) as _:
20
        _button_data_extractor((1, {"wrong": "text", }))
21