diff options
| author | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2014-01-19 18:46:21 +0200 |
|---|---|---|
| committer | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2014-01-19 18:46:21 +0200 |
| commit | 9954b4b99d9119ea55b1c204b12bad1e7b45589b (patch) | |
| tree | e255bbc57931fa3ab338e876d359e138639bd6ff /tests | |
| parent | 8c3858b01623f9527b57b13c44ff97c67bafb00b (diff) | |
Add directory for I/O tests with basic test for file methods.
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/io/data/file1 | 3 | ||||
| -rw-r--r-- | tests/io/file1.py | 4 | ||||
| -rwxr-xr-x | tests/run-tests | 2 |
3 files changed, 8 insertions, 1 deletions
diff --git a/tests/io/data/file1 b/tests/io/data/file1 new file mode 100644 index 000000000..e08206337 --- /dev/null +++ b/tests/io/data/file1 @@ -0,0 +1,3 @@ +longer line1 +line2 +line3 diff --git a/tests/io/file1.py b/tests/io/file1.py new file mode 100644 index 000000000..8552f535b --- /dev/null +++ b/tests/io/file1.py @@ -0,0 +1,4 @@ +f = open("io/data/file1") +print(f.read(5)) +print(f.readline()) +print(f.read()) diff --git a/tests/run-tests b/tests/run-tests index 7ab128133..318920b5e 100755 --- a/tests/run-tests +++ b/tests/run-tests @@ -10,7 +10,7 @@ numpassed=0 numfailed=0 namefailed= -for infile in basics/*.py +for infile in basics/*.py io/*.py do basename=`basename $infile .py` outfile=${basename}.out |
