OLD | NEW |
1 # Copyright (C) 2010 Google Inc. All rights reserved. | 1 # Copyright (C) 2010 Google Inc. All rights reserved. |
2 # Copyright (C) 2010 Gabor Rapcsanyi (rgabor@inf.u-szeged.hu), University of Sze
ged | 2 # Copyright (C) 2010 Gabor Rapcsanyi (rgabor@inf.u-szeged.hu), University of Sze
ged |
3 # | 3 # |
4 # Redistribution and use in source and binary forms, with or without | 4 # Redistribution and use in source and binary forms, with or without |
5 # modification, are permitted provided that the following conditions are | 5 # modification, are permitted provided that the following conditions are |
6 # met: | 6 # met: |
7 # | 7 # |
8 # * Redistributions of source code must retain the above copyright | 8 # * Redistributions of source code must retain the above copyright |
9 # notice, this list of conditions and the following disclaimer. | 9 # notice, this list of conditions and the following disclaimer. |
10 # * Redistributions in binary form must reproduce the above | 10 # * Redistributions in binary form must reproduce the above |
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
171 dir_name = '/tmp/layout-test-results' + '_' + str(x) | 171 dir_name = '/tmp/layout-test-results' + '_' + str(x) |
172 self._make_fake_test_result(port.host, dir_name) | 172 self._make_fake_test_result(port.host, dir_name) |
173 manager = get_manager() | 173 manager = get_manager() |
174 manager._limit_archived_results_count() | 174 manager._limit_archived_results_count() |
175 deleted_dir_count = 0 | 175 deleted_dir_count = 0 |
176 for x in range(1, 31): | 176 for x in range(1, 31): |
177 dir_name = '/tmp/layout-test-results' + '_' + str(x) | 177 dir_name = '/tmp/layout-test-results' + '_' + str(x) |
178 if not port.host.filesystem.exists(dir_name): | 178 if not port.host.filesystem.exists(dir_name): |
179 deleted_dir_count = deleted_dir_count + 1 | 179 deleted_dir_count = deleted_dir_count + 1 |
180 self.assertEqual(deleted_dir_count, 5) | 180 self.assertEqual(deleted_dir_count, 5) |
| 181 |
| 182 def test_copies_manifest_if_not_there_already(self): |
| 183 host = MockHost() |
| 184 port = host.port_factory.get('test-mac-mac10.10') |
| 185 port.host.filesystem.write_binary_file('/test.checkout/LayoutTests/exter
nal/WPT_BASE_MANIFEST.json', '{}') |
| 186 |
| 187 self.assertFalse(port.host.filesystem.exists('/test.checkout/LayoutTests
/external/wpt/MANIFEST.json')) |
| 188 manager = Manager(port, options=optparse.Values({'max_locked_shards': 1}
), printer=FakePrinter()) |
| 189 manager.run([]) |
| 190 self.assertTrue(port.host.filesystem.exists('/test.checkout/LayoutTests/
external/wpt/MANIFEST.json')) |
OLD | NEW |