tests/extmod/vfs_fat_fileio: Add test for constructor of FileIO type.

This commit is contained in:
Damien George 2016-12-02 15:37:58 +11:00
parent f7545b200e
commit 6194336d81
2 changed files with 6 additions and 0 deletions

View File

@ -89,6 +89,11 @@ with vfs.open("foo_file.txt") as f2:
f2.seek(-2, 2) # SEEK_END
print(f2.read(1))
# using constructor of FileIO type to open a file
FileIO = type(f)
with FileIO("foo_file.txt") as f:
print(f.read())
# dirs
vfs.mkdir("foo_dir")

View File

@ -9,6 +9,7 @@ h
e
True
d
hello!world!
True
True
True