mirror of
https://github.com/brain-hackers/u-boot-brain
synced 2024-09-28 23:50:26 +09:00
test/py: hush_if_test: Use open() in place of file()
In python 3.x the file() function has been removed. Use open() instead, which works on both python 2.x & 3.x, and is described as the preferred method of opening a file by python 2.x documentation anyway. Signed-off-by: Paul Burton <paul.burton@imgtec.com> Reviewed-by: Stephen Warren <swarren@nvidia.com>
This commit is contained in:
parent
57bf9bea34
commit
9f9e8a4dda
@ -148,7 +148,7 @@ def test_hush_if_test_host_file_exists(u_boot_console):
|
||||
exec_hush_if(u_boot_console, expr, False)
|
||||
|
||||
try:
|
||||
with file(test_file, 'wb'):
|
||||
with open(test_file, 'wb'):
|
||||
pass
|
||||
assert os.path.exists(test_file)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user