Skip to content

Commit 3c485cb

Browse files
committed
docs: add simple tests data
1 parent 4e02ef2 commit 3c485cb

2 files changed

Lines changed: 38 additions & 1 deletion

File tree

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,3 +125,5 @@ $RECYCLE.BIN/
125125
homoglitch.go
126126
homoglyph.go
127127
build
128+
alice29*
129+
plrabn12*

README.md

Lines changed: 36 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ is always generated
2727

2828
```bash
2929
for _ in {0..10}; do
30-
echo 'Just a random string for example!' | ./homoglitch | wc -c | tr -d '\n'
30+
echo 'Just a random string for example!' | homoglitch | wc -c | tr -d '\n'
3131
printf ' '
3232
done
3333

@@ -80,3 +80,38 @@ rm homoglitch.go
8080

8181
The glitch.txt file is based on
8282
[codebox/homoglyph](http://github.com/codebox/homoglyph).
83+
84+
## some tests
85+
86+
Test data files 149K `alice29.txt` and 471K `plrabn12.txt` from
87+
<https://corpus.canterbury.ac.nz/descriptions/>
88+
89+
```bash
90+
sync; time homoglyph < alice29.txt > alice29-glyph.txt
91+
92+
real 0m0,048s
93+
user 0m0,000s
94+
sys 0m0,000s
95+
# 436K alice29-glyph.txt
96+
97+
sync; time homoglitch < alice29.txt > alice29-glitch.txt
98+
99+
real 0m0,052s
100+
user 0m0,000s
101+
sys 0m0,000s
102+
# 664K alice29-glitch.txt
103+
104+
sync; time homoglyph < plrabn12.txt > plrabn12-glyph.txt
105+
106+
real 0m0,099s
107+
user 0m0,000s
108+
sys 0m0,000s
109+
# 1,4M plrabn12-glyph.txt
110+
111+
sync; time homoglitch < plrabn12.txt > plrabn12-glitch.txt
112+
113+
real 0m0,107s
114+
user 0m0,000s
115+
sys 0m0,000s
116+
# 2,2M plrabn12-glitch.txt
117+
```

0 commit comments

Comments
 (0)