Skip to content

Commit ef27d83

Browse files
author
zhenwei-li
committed
the git test suite upgrade
1 parent 5a10c8a commit ef27d83

1 file changed

Lines changed: 14 additions & 12 deletions

File tree

tests/com/dvsnier/git/test_git.py

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,45 @@
11
# -*- coding:utf-8 -*-
22

3-
from com.dvsnier.git.git import Git
43
import logging
54
import unittest
65

6+
from com.dvsnier.git.git import Git
77

88
class Test_Git(unittest.TestCase):
99
''' the test git '''
10+
1011
@classmethod
1112
def setUpClass(cls):
1213
print("...the set up...")
13-
print
14+
print('')
15+
cls._git = Git()
16+
cls._git.config()
1417

1518
def setUp(self):
16-
return super(Test_Git, self).setUp()
19+
super(Test_Git, self).setUp()
1720

1821
def test_config(self):
1922
''' the test config
2023
note:
2124
1. the currently, only one process instance log object is supported.
2225
2. the following consideration is to support multi process and multi instance log objects
2326
'''
24-
git = Git()
25-
self.assertIsNotNone(git, 'test_config is error.')
26-
git.config()
27-
# git.config(output_dir_name='test_git')
28-
# git.config(file_name='record')
29-
# git.config(output_dir_name='test_git', file_name='record')
27+
self.assertIsNotNone(Test_Git._git, 'test_config is error.')
28+
# Test_Git._git.config(output_dir_name='test_git')
29+
# Test_Git._git.config(file_name='record')
30+
# Test_Git._git.config(output_dir_name='test_git', file_name='record')
3031
logging.warn('the test config is succeed.')
3132
print("the test config is succeed.")
3233

3334
def tearDown(self):
34-
return super(Test_Git, self).tearDown()
35+
super(Test_Git, self).tearDown()
3536

3637
@classmethod
3738
def tearDownClass(cls):
38-
print
39+
print('')
3940
print("...the tear down...")
4041

4142

4243
if __name__ == '__main__':
43-
unittest.main()
44+
suite = unittest.TestLoader().loadTestsFromTestCase(Test_Git)
45+
unittest.TextTestRunner(verbosity=2).run(suite)

0 commit comments

Comments
 (0)