mirror of
https://gitee.com/zlgopen/awtk.git
synced 2024-11-30 19:18:53 +08:00
29 lines
803 B
GLSL
29 lines
803 B
GLSL
assert(file_write("test.txt", "hello"))
|
|
assert(file_exist("test.txt"))
|
|
assert(file_get_size("test.txt")==5)
|
|
assert(file_read_text("test.txt") == "hello")
|
|
assert(file_remove("test.txt"))
|
|
assert(!file_exist("test.txt"))
|
|
|
|
assert(file_write("test.bin", "hello", 5))
|
|
assert(file_exist("test.bin"))
|
|
assert(file_get_size("test.bin")==5)
|
|
a = file_read_binary("test.bin")
|
|
assert(value_get_binary_size(a) == 5)
|
|
assert(file_remove("test.bin"))
|
|
assert(!file_exist("test.bin"))
|
|
|
|
assert(file_write("test.bin", a))
|
|
assert(file_exist("test.bin"))
|
|
assert(file_get_size("test.bin")==5)
|
|
assert(file_remove("test.bin"))
|
|
|
|
assert(path_create("a/b/c"))
|
|
assert(path_exist("a/b/c"))
|
|
assert(path_remove("a/b/c"))
|
|
assert(!path_exist("a/b/c"))
|
|
|
|
print(path_get_temp())
|
|
print(path_get_app_root())
|
|
print(path_get_user_storage_root())
|