File tree 4 files changed +66
-1
lines changed
4 files changed +66
-1
lines changed Original file line number Diff line number Diff line change 1
1
bumpversion == 0.5.3
2
2
PyGithub == 1.26.0
3
- docopt == 0.6.2
3
+ docopt == 0.6.2
4
+ xmlrunner == 1.7.7
Original file line number Diff line number Diff line change
1
+ import tests
2
+
3
+ tests .run_tests ()
Original file line number Diff line number Diff line change
1
+ import os
2
+ import xmlrunner
3
+
4
+
5
+ import all_tests
6
+
7
+
8
+ def run_tests ():
9
+ output = 'test-reports/githubtools'
10
+
11
+ suites = [
12
+ all_tests
13
+ ]
14
+
15
+ for suite in suites :
16
+ xmlrunner .XMLTestRunner (output = output ).run (suite .get_suite ())
17
+ os .system ('cls' if os .name == 'nt' else 'clear' )
Original file line number Diff line number Diff line change
1
+ import unittest
2
+
3
+ import githubtools .commit_status
4
+ import githubtools .create_pull_request
5
+ import githubtools .merge_pull_request
6
+
7
+ from docopt import DocoptExit
8
+
9
+
10
+ class GithubtoolsTests (unittest .TestCase ):
11
+
12
+ def test_commit_status_no_args (self ):
13
+ try :
14
+ githubtools .commit_status .main ()
15
+ except DocoptExit as e :
16
+ print str (e )
17
+ self .assertTrue (str (e ).startswith ("Usage:" ))
18
+ else :
19
+ self .assertTrue (False )
20
+
21
+ def test_create_pull_request_no_args (self ):
22
+ try :
23
+ githubtools .create_pull_request .main ()
24
+ except DocoptExit as e :
25
+ print str (e )
26
+ self .assertTrue (str (e ).startswith ("Usage:" ))
27
+ else :
28
+ self .assertTrue (False )
29
+
30
+ def test_merge_pull_request_no_args (self ):
31
+ try :
32
+ githubtools .merge_pull_request .main ()
33
+ except DocoptExit as e :
34
+ print str (e )
35
+ self .assertTrue (str (e ).startswith ("Usage:" ))
36
+ else :
37
+ self .assertTrue (False )
38
+
39
+ def get_suite ():
40
+ return unittest .TestLoader ().loadTestsFromTestCase (GithubtoolsTests )
41
+
42
+
43
+ if __name__ == "__main__" :
44
+ unittest .main ()
You can’t perform that action at this time.
0 commit comments