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

Unified Diff: recipe_modules/file/example.disable

Issue 2993713003: Add file.filesizes to recipe engine core modules. (Closed)
Patch Set: -kwargs. Created 3 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « recipe_modules/file/api.py ('k') | recipe_modules/file/examples/copytree.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: recipe_modules/file/example.disable
diff --git a/recipe_modules/file/example.disable b/recipe_modules/file/example.disable
index 3cd41fad6d37274df12b60f554faecf754a18cb7..90a9cbc1fad63c60dd1e3086127d2c1ff2d0e6d9 100644
--- a/recipe_modules/file/example.disable
+++ b/recipe_modules/file/example.disable
@@ -34,6 +34,12 @@ def RunSteps(api):
for element in result:
api.step('manipulate %s' % str(element), ['some', 'command'])
+ # filesizes demo.
+ filepaths = ['/fake/one', '/fake/other']
+ sizes = api.file.filesizes('filesizes', filepaths)
+ for f, s in zip(filepaths, sizes):
+ api.step('filesize of %s is %d bytes' % (f, s))
+
# mkdtemp demo.
for prefix in ('prefix_a', 'prefix_b'):
# Create temp dir.
@@ -92,5 +98,6 @@ def RunSteps(api):
def GenTests(api):
- yield api.test('file_io') + api.file.listdir('other', ['aaa'])
-
+ yield (api.test('file_io')
+ + api.file.listdir('other', ['aaa'])
+ + api.file.filesizes([1, 44]))
« no previous file with comments | « recipe_modules/file/api.py ('k') | recipe_modules/file/examples/copytree.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698