aboutsummaryrefslogtreecommitdiff
path: root/tests/hello_world_file.cpp
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2012-04-18 19:22:09 -0700
committerAlon Zakai <alonzakai@gmail.com>2012-04-18 19:22:09 -0700
commit1c11fdd98530b6d35e51c0eba14fb1f375d05229 (patch)
treebd471ce02003d0e1d16dfe773d1ed4d0acdcb499 /tests/hello_world_file.cpp
parentd6cff2177ec065aa14f228ab547abc29ef37b248 (diff)
parent327b6f859e95be71e5613f24cc1c9d4f4b97c15f (diff)
merge
Diffstat (limited to 'tests/hello_world_file.cpp')
-rw-r--r--tests/hello_world_file.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/hello_world_file.cpp b/tests/hello_world_file.cpp
new file mode 100644
index 00000000..71fb953b
--- /dev/null
+++ b/tests/hello_world_file.cpp
@@ -0,0 +1,13 @@
+#include <stdio.h>
+int main() {
+ FILE *file = fopen("tests/hello_world_file.txt", "rb");
+ while (!feof(file)) {
+ char c = fgetc(file);
+ if (c != EOF) {
+ putchar(c);
+ }
+ }
+ fclose (file);
+ return 0;
+}
+