diff --git a/integrationtests/test.sh b/integrationtests/test.sh index a142d917215eb7469faab9c66a581539ce867e4e..5bb013db6e70a3a8393e7e3b7c7993a6da6bf9b9 100755 --- a/integrationtests/test.sh +++ b/integrationtests/test.sh @@ -35,14 +35,17 @@ echo "Testing the crawler database" python3 -m pytest test_crawler_with_cfoods.py echo "make a change" cd extroot -egrep -liRZ 'A description of another example' . | xargs -0 -l sed -i -e 's/A description of another example/A description of this example/g' +egrep -liRZ 'A description of another example' . \ + | xargs -0 -l sed -i -e 's/A description of another example/A description of this example/g' # remove a file to check that this does not lead to a crawler crash -mv DataAnalysis/2010_TestProject/2019-02-03_something/README.xlsx DataAnalysis/2010_TestProject/2019-02-03_something/README.xlsx_back +mv DataAnalysis/2010_TestProject/2019-02-03_something/README.xlsx \ + DataAnalysis/2010_TestProject/2019-02-03_something/README.xlsx_back cd .. echo "run crawler" ./crawl.py / | tee $OUT # rename the moved file -mv extroot/DataAnalysis/2010_TestProject/2019-02-03_something/README.xlsx_back extroot/DataAnalysis/2010_TestProject/2019-02-03_something/README.xlsx +mv extroot/DataAnalysis/2010_TestProject/2019-02-03_something/README.xlsx_back \ + extroot/DataAnalysis/2010_TestProject/2019-02-03_something/README.xlsx # check whether there was something UNAUTHORIZED grep "There where unauthorized changes" $OUT # get the id of the run which is the last field of the output string @@ -59,7 +62,8 @@ fi set -e echo "Undoing previous changes to extroot content..." cd extroot -egrep -liRZ 'A description of this example' . | xargs -0 -l sed -i -e 's/A description of this example/A description of another example/g' +egrep -liRZ 'A description of this example' . \ + | xargs -0 -l sed -i -e 's/A description of this example/A description of another example/g' cd .. echo "Done." python3 test_table.py