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

Side by Side Diff: swarm_client/tests/isolate/touch_only.py

Issue 69143004: Delete swarm_client. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 #!/usr/bin/env python
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
5
6 import os
7 import sys
8
9
10 def main():
11 print 'touch_only: verify the file is empty.'
12 assert len(sys.argv) == 2
13 mode = sys.argv[1]
14 assert mode in ('run', 'trace')
15
16 size = os.stat(os.path.join('files1', 'test_file1.txt')).st_size
17 if mode == 'run':
18 # The file must be empty.
19 if size:
20 print 'Unexpected content'
21 return 1
22 else:
23 # The file must be non-empty.
24 if not size:
25 print 'Unexpected emptiness'
26 return 1
27 return 0
28
29
30 if __name__ == '__main__':
31 sys.exit(main())
OLDNEW
« no previous file with comments | « swarm_client/tests/isolate/touch_only.isolate ('k') | swarm_client/tests/isolate/touch_root.isolate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698