| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # coding: utf-8 | 2 # coding: utf-8 |
| 3 # Copyright 2013 The LUCI Authors. All rights reserved. | 3 # Copyright 2013 The LUCI Authors. All rights reserved. |
| 4 # Use of this source code is governed under the Apache License, Version 2.0 | 4 # Use of this source code is governed under the Apache License, Version 2.0 |
| 5 # that can be found in the LICENSE file. | 5 # that can be found in the LICENSE file. |
| 6 | 6 |
| 7 import datetime | 7 import datetime |
| 8 import itertools | 8 import itertools |
| 9 import json | 9 import json |
| 10 import logging | 10 import logging |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 '/auth/', | 108 '/auth/', |
| 109 ) | 109 ) |
| 110 | 110 |
| 111 public_urls = frozenset([ | 111 public_urls = frozenset([ |
| 112 '/', | 112 '/', |
| 113 '/_ah/warmup', | 113 '/_ah/warmup', |
| 114 '/api/config/v1/validate', | 114 '/api/config/v1/validate', |
| 115 '/auth', | 115 '/auth', |
| 116 '/ereporter2/api/v1/on_error', | 116 '/ereporter2/api/v1/on_error', |
| 117 '/stats', | 117 '/stats', |
| 118 '/api/swarming/v1/server/permissions', |
| 118 '/swarming/api/v1/client/list', | 119 '/swarming/api/v1/client/list', |
| 119 '/swarming/api/v1/bot/server_ping', | 120 '/swarming/api/v1/bot/server_ping', |
| 120 '/swarming/api/v1/stats/summary/<resolution:[a-z]+>', | 121 '/swarming/api/v1/stats/summary/<resolution:[a-z]+>', |
| 121 '/swarming/api/v1/stats/dimensions/<dimensions:.+>/<resolution:[a-z]+>', | 122 '/swarming/api/v1/stats/dimensions/<dimensions:.+>/<resolution:[a-z]+>', |
| 122 '/swarming/api/v1/stats/user/<user:.+>/<resolution:[a-z]+>', | 123 '/swarming/api/v1/stats/user/<user:.+>/<resolution:[a-z]+>', |
| 123 ]) | 124 ]) |
| 124 | 125 |
| 125 # Grab the set of all routes. | 126 # Grab the set of all routes. |
| 126 app = self.app.app | 127 app = self.app.app |
| 127 routes = set(app.router.match_routes) | 128 routes = set(app.router.match_routes) |
| (...skipping 438 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 566 url, headers={'X-AppEngine-QueueName': 'bogus name'}, status=403) | 567 url, headers={'X-AppEngine-QueueName': 'bogus name'}, status=403) |
| 567 | 568 |
| 568 | 569 |
| 569 if __name__ == '__main__': | 570 if __name__ == '__main__': |
| 570 if '-v' in sys.argv: | 571 if '-v' in sys.argv: |
| 571 unittest.TestCase.maxDiff = None | 572 unittest.TestCase.maxDiff = None |
| 572 logging.basicConfig( | 573 logging.basicConfig( |
| 573 level=logging.DEBUG if '-v' in sys.argv else logging.CRITICAL, | 574 level=logging.DEBUG if '-v' in sys.argv else logging.CRITICAL, |
| 574 format='%(levelname)-7s %(filename)s:%(lineno)3d %(message)s') | 575 format='%(levelname)-7s %(filename)s:%(lineno)3d %(message)s') |
| 575 unittest.main() | 576 unittest.main() |
| OLD | NEW |