OLD | NEW |
1 #!/usr/bin/python2.6.2 | 1 #!/usr/bin/python2.6.2 |
2 # Copyright 2009, Google Inc. | 2 # Copyright 2009, Google Inc. |
3 # All rights reserved. | 3 # All rights reserved. |
4 # | 4 # |
5 # Redistribution and use in source and binary forms, with or without | 5 # Redistribution and use in source and binary forms, with or without |
6 # modification, are permitted provided that the following conditions are | 6 # modification, are permitted provided that the following conditions are |
7 # met: | 7 # met: |
8 # | 8 # |
9 # * Redistributions of source code must retain the above copyright | 9 # * Redistributions of source code must retain the above copyright |
10 # notice, this list of conditions and the following disclaimer. | 10 # notice, this list of conditions and the following disclaimer. |
(...skipping 24 matching lines...) Expand all Loading... |
35 | 35 |
36 import logging | 36 import logging |
37 import os | 37 import os |
38 import subprocess | 38 import subprocess |
39 import shutil | 39 import shutil |
40 import sys | 40 import sys |
41 | 41 |
42 import runner_constants as const | 42 import runner_constants as const |
43 import util | 43 import util |
44 | 44 |
45 CHANGE_RESOLUTION_PATH = (const.O3D_PATH + '/o3d/tests/lab' | 45 CHANGE_RESOLUTION_PATH = os.path.join(const.TEST_PATH, 'lab', |
46 '/ChangeResolution/Debug/changeresolution.exe') | 46 'ChangeResolution','Debug', |
| 47 'changeresolution.exe') |
47 | 48 |
48 def EnsureWindowsScreenResolution(width, height, bpp): | 49 def EnsureWindowsScreenResolution(width, height, bpp): |
49 """Performs all steps needed to configure system for testing on Windows. | 50 """Performs all steps needed to configure system for testing on Windows. |
50 | 51 |
51 Args: | 52 Args: |
52 width: new screen resolution width | 53 width: new screen resolution width |
53 height: new screen resolution height | 54 height: new screen resolution height |
54 bpp: new screen resolution bytes per pixel | 55 bpp: new screen resolution bytes per pixel |
55 Returns: | 56 Returns: |
56 True on success. | 57 True on success. |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
155 return not DoesAnO3DPluginExist() | 156 return not DoesAnO3DPluginExist() |
156 | 157 |
157 def DoesAnO3DPluginExist(): | 158 def DoesAnO3DPluginExist(): |
158 for path in const.INSTALL_PATHS: | 159 for path in const.INSTALL_PATHS: |
159 if os.path.exists(path): | 160 if os.path.exists(path): |
160 return True | 161 return True |
161 return False | 162 return False |
162 | 163 |
163 | 164 |
164 | 165 |
OLD | NEW |