forked from cory/tildefriends
Remove unused file operations.
git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4263 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
30
src/tests.c
30
src/tests.c
@ -542,36 +542,6 @@ static void _test_file(const tf_test_options_t* options)
|
||||
" exit(1);\n"
|
||||
"}).catch(function(error) {\n"
|
||||
" print('expected error', error);\n"
|
||||
"});\n"
|
||||
"File.unlinkFile('out/test/new.txt').finally(function() {\n"
|
||||
" return File.removeDirectory('out/test');\n"
|
||||
"}).finally(function() {\n"
|
||||
" return File.makeDirectory('out/test').then(function() {\n"
|
||||
" return File.writeFile('out/test/new.txt', 'hello').then(function(result) {\n"
|
||||
" return File.readFile('out/test/new.txt').then(function(data) {\n"
|
||||
" if (utf8Decode(data) != 'hello') {\n"
|
||||
" print('READ', utf8Decode(data));\n"
|
||||
" exit(1);\n"
|
||||
" }\n"
|
||||
" }).catch(function(error) {\n"
|
||||
" print('unexpected read error', error);\n"
|
||||
" exit(1);\n"
|
||||
" });\n"
|
||||
" }).catch(function(error) {\n"
|
||||
" print('unexpected write error', error);\n"
|
||||
" exit(1);\n"
|
||||
" });\n"
|
||||
" }).catch(function(error) {\n"
|
||||
" print('unexpected make directory error', error);\n"
|
||||
" exit(1);\n"
|
||||
" });\n"
|
||||
"}).finally(function() {\n"
|
||||
" return File.renameFile('out/test/new.txt', 'out/test/renamed.txt').catch(x => print(x)).finally(function() {\n"
|
||||
" return File.unlinkFile('out/test/renamed.txt').catch(x => print(x)).finally(function() {\n"
|
||||
" print('removing directory');\n"
|
||||
" return File.removeDirectory('out/test').catch(x => print(x));\n"
|
||||
" });\n"
|
||||
" });\n"
|
||||
"});\n");
|
||||
fclose(file);
|
||||
|
||||
|
Reference in New Issue
Block a user