Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(761)

Side by Side Diff: recipe_engine/unittests/recipe_api_test.py

Issue 2702313003: Remove unused imports and fix some other linter errors. (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright 2015 The LUCI Authors. All rights reserved. 2 # Copyright 2015 The LUCI Authors. All rights reserved.
3 # Use of this source code is governed under the Apache License, Version 2.0 3 # Use of this source code is governed under the Apache License, Version 2.0
4 # that can be found in the LICENSE file. 4 # that can be found in the LICENSE file.
5 5
6 import os
7 import sys
8 import unittest 6 import unittest
9 7
10 import test_env 8 import test_env
11 9
12 from recipe_engine import recipe_api, config 10 from recipe_engine import recipe_api, config
13 11
14 def make_prop(**kwargs): 12 def make_prop(**kwargs):
15 name = kwargs.pop('name', "dumb_name") 13 name = kwargs.pop('name', "dumb_name")
16 return recipe_api.Property(**kwargs).bind(name, 'test', 'properties_test') 14 return recipe_api.Property(**kwargs).bind(name, 'test', 'properties_test')
17 15
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 Tests setting a param name correctly carries through to a bound property. 79 Tests setting a param name correctly carries through to a bound property.
82 """ 80 """
83 prop = recipe_api.Property(param_name='good_name') 81 prop = recipe_api.Property(param_name='good_name')
84 bound = prop.bind('bad.name-time', 'test', 'test_me') 82 bound = prop.bind('bad.name-time', 'test', 'test_me')
85 83
86 self.assertEqual('good_name', bound.param_name) 84 self.assertEqual('good_name', bound.param_name)
87 85
88 86
89 if __name__ == '__main__': 87 if __name__ == '__main__':
90 unittest.main() 88 unittest.main()
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698