blob: 282ec85732cdcaa8eec89eb8c8bb26b3f00d65f7 [file] [log] [blame]
epoger33ac9502014-07-16 08:28:23 -07001#!/usr/bin/python
2
3"""
4Copyright 2014 Google Inc.
5
6Use of this source code is governed by a BSD-style license that can be
7found in the LICENSE file.
8
9Run all unittests within this directory tree, recursing into subdirectories.
10"""
11
12import os
13import unittest
14
15
16def main():
17 suite = unittest.TestLoader().discover(os.path.dirname(__file__),
18 pattern='*_test.py')
19 results = unittest.TextTestRunner(verbosity=2).run(suite)
20 print repr(results)
21 if not results.wasSuccessful():
22 raise Exception('failed one or more unittests')
23
24if __name__ == '__main__':
25 main()