summaryrefslogtreecommitdiffstatshomepage
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/extmod/vfs_fat_ramdisk.py6
-rw-r--r--tests/extmod/vfs_fat_ramdisk.py.exp1
2 files changed, 7 insertions, 0 deletions
diff --git a/tests/extmod/vfs_fat_ramdisk.py b/tests/extmod/vfs_fat_ramdisk.py
index 89b40e3a24..fe72a8beff 100644
--- a/tests/extmod/vfs_fat_ramdisk.py
+++ b/tests/extmod/vfs_fat_ramdisk.py
@@ -93,3 +93,9 @@ uos.umount(vfs)
vfs = uos.VfsFat(bdev)
print(list(vfs.ilistdir(b"")))
+
+# list a non-existent directory
+try:
+ vfs.ilistdir(b"no_exist")
+except OSError as e:
+ print('ENOENT:', e.args[0] == uerrno.ENOENT)
diff --git a/tests/extmod/vfs_fat_ramdisk.py.exp b/tests/extmod/vfs_fat_ramdisk.py.exp
index 6298a7efdc..ccd0f7134c 100644
--- a/tests/extmod/vfs_fat_ramdisk.py.exp
+++ b/tests/extmod/vfs_fat_ramdisk.py.exp
@@ -13,3 +13,4 @@ getcwd: /foo_dir
True
getcwd: /
[(b'foo_file.txt', 32768, 0), (b'foo_dir', 16384, 0)]
+ENOENT: True