X-Git-Url: http://lists.indexdata.dk/cgi-bin?a=blobdiff_plain;ds=sidebyside;f=test%2Fwidgets%2FMakefile;h=5d731c0acfd198246d5fc8aa171b5bfc91955a8b;hb=c4a892ed9cba0c10e9e7257137acf4c7580f3b86;hp=8a0dbd062eb7e55f23211ae76620fb622cefa742;hpb=62b303b34d69f9cf1f18e9351a00317a3331ee40;p=mkws-moved-to-github.git diff --git a/test/widgets/Makefile b/test/widgets/Makefile index 8a0dbd0..5d731c0 100644 --- a/test/widgets/Makefile +++ b/test/widgets/Makefile @@ -7,6 +7,7 @@ SCREENSHOT_WIDTH_HEIGHT= 1000 1200 PERL_SCRIPTS= ../bin/bomb.pl PROG= ../phantom/screenshot.js MD5= $(shell which md5 md5sum) +URL_FILE= koha.url TIMEOUT=5 PHANTOMJS_URL= http://cph.koha.indexdata.com/cgi-bin/koha/opac-search.pl?q=sushi @@ -16,7 +17,7 @@ all: help clean: rm -f mkws-error.png mkws-error.html - rm -f ${IMAGES}/*.png + rm -f ${IMAGES}/*.png ${IMAGES}/*.png.tmp rm -f ${IMAGES}/index.html distclean: clean @@ -25,13 +26,14 @@ test: check screenshot: file=$$(echo "${PHANTOMJS_URL}" | perl -npe 's,(\W),-,g'); \ - ${PHANTOMJS} ${PROG} ${PHANTOMJS_URL} ${IMAGES}/$$file.png ${SCREENSHOT_WIDTH_HEIGHT} ${TIMEOUT} + ${PHANTOMJS} ${PROG} ${PHANTOMJS_URL} ${IMAGES}/tmp.$$file.png ${SCREENSHOT_WIDTH_HEIGHT} ${TIMEOUT}; \ + mv -f ${IMAGES}/tmp.$$file.png ${IMAGES}/$$file.png -screenshots: - for i in $$(cat url.txt); do \ - make PHANTOMJS_URL="$$i" TIMEOUT=4 screenshot; \ +screenshots: clean + for i in $$(cat ${URL_FILE}); do \ + ${MAKE} PHANTOMJS_URL="$$i" TIMEOUT=4 screenshot; \ done; wait - make index + ${MAKE} index index: cd ${IMAGES}; ls -tr *.png | perl -ne 'chomp; print qq{