forked from yubin-park/drgpy
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmdc00_tests.py
74 lines (54 loc) · 2.5 KB
/
mdc00_tests.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
import unittest
from drgpy.msdrg import DRGEngine
class TestMCD00(unittest.TestCase):
def test_mdcs00(self):
de = DRGEngine()
drg_lst = de.get_drg_all(["I10", "E0800"], ["02YA0Z0"])
self.assertTrue("001" in drg_lst)
drg_lst = de.get_drg_all(["I10"], ["02YA0Z0"])
self.assertTrue("002" in drg_lst)
drg_lst = de.get_drg_all([], ["02HA0RS"])
self.assertTrue("002" not in drg_lst)
drg_lst = de.get_drg_all([], ["02HA0RS", "02PA0RZ"])
self.assertTrue("002" in drg_lst)
drg_lst = de.get_drg_all([], ["5A1522F"])
self.assertTrue("003" in drg_lst)
drg_lst = de.get_drg_all([], ["0B110F4", "5A1955Z"])
self.assertTrue("003" in drg_lst)
drg_lst = de.get_drg_all(["E0800"], ["0B110F4"])
self.assertTrue("003" in drg_lst)
drg_lst = de.get_drg_all(["A360"], ["0B110F4"])
self.assertTrue("004" not in drg_lst)
drg_lst = de.get_drg_all([], ["0FY00Z0", "0DY80Z0"])
self.assertTrue("005" in drg_lst)
drg_lst = de.get_drg_all(["I10", "E0800"], ["0FY00Z0"])
self.assertTrue("005" in drg_lst)
drg_lst = de.get_drg_all([], ["0DY80Z0"])
self.assertTrue("005" in drg_lst)
drg_lst = de.get_drg_all([], ["0FY00Z0"])
self.assertTrue("006" in drg_lst)
drg_lst = de.get_drg_all([], ["30230G2"])
self.assertTrue("014" in drg_lst)
drg_lst = de.get_drg_all([], ["0BYC0Z0"])
self.assertTrue("007" in drg_lst)
drg_lst = de.get_drg_all(["I120", "E0800"], ["0TY00Z0", "0FYG0Z0"])
self.assertTrue("008" in drg_lst)
drg_lst = de.get_drg_all(["I120"], ["0TY00Z0", "0FYG0Z0"])
self.assertTrue("008" not in drg_lst)
drg_lst = de.get_drg_all([], ["XW033C3"])
self.assertTrue("016" in drg_lst)
drg_lst = de.get_drg_all(["I10", "E0800"], ["30230AZ"])
self.assertTrue("304" in drg_lst)
drg_lst = de.get_drg_all([], ["30230AZ"])
# in v37, this is 983, used to be 017
self.assertTrue("983" in drg_lst)
drg_lst = de.get_drg_all(["E0800"], ["0FYG0Z0"])
self.assertTrue("010" in drg_lst)
drg_lst = de.get_drg_all(["A360", "E0800"], ["0B110F4"])
self.assertTrue("011" in drg_lst)
drg_lst = de.get_drg_all(["A360", "A000"], ["0B110F4"])
self.assertTrue("012" in drg_lst)
drg_lst = de.get_drg_all(["A360"], ["0B110F4"])
self.assertTrue("013" in drg_lst)
if __name__=="__main__":
unittest.main()