summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--Makefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 8dc42f0..6b730a8 100644
--- a/Makefile
+++ b/Makefile
@@ -16,6 +16,11 @@ words-qwerty-en: /usr/share/dict/american-english mapScore
 /usr/share/dict/american-english:
 	apk add words-en
 
+test: words-qwerty-en swipeGuess
+	test `echo "asdfghjkl" | ./swipeGuess words-qwerty-en` = "all"
+	test `echo "dfghuiokmnhyt" | ./swipeGuess words-qwerty-en 1 "'"` = "don't"
+	test "`echo "tyuiopoiuytrewertyuiuytrer" | ./swipeGuess words-qwerty-en 2`" = "`printf "typewriter\ttorturer"`"
+
 install: all
 	install -m755 swipeGuess -D -t "$(DESTDIR)/$(PREFIX)/bin/"
 	install -m755 mapScore -D -t "$(DESTDIR)/$(PREFIX)/bin/"