« Auto-éditer un wikilivre/Annexer (Version internationalisée)/src/header.inc.sh » : différence entre les versions

Contenu supprimé Contenu ajouté
m →‎src/header.inc.sh : Correction de coquilles
Ligne 241 :
#P Syntax ./tests_header.inc.bash
 
VERSION=210519210522
 
#O Clean screen
clear
#PO Include install variables
 
#P Include install variables
pwd > pwd.txt
if cat pwd.txt | grep ~/Annexer; then Workdir=~/Annexer; elif cat pwd.txt | grep ~/Add_appendix; \
then Workdir=~/Add_appendix; else echo "Workind directory not found"; exit -1;fi
rm pwd.txt
#O Download global variables
source $Workdir/vars/installdir.var
#PO Print command headertest_header.inc.shbash version
#P Print echo " test_header.inc.bash version = $VERSION"
echo " test-header.inc.bash version = $VERSION"
sleep 2
#T echo "----"
#O Print command header.inc.sh version
#P Print command header.inc.sh version
#T echo "Command header.inc.sh --v to veriy header.inc version"
./header.inc.sh --v
echo;echo " wait for 2 sec"
sleep 2; echo "----"
#O Control if the test header.inc.sh file is clean
echo -e "\033[1;33m Control header.inc.sh in the local test directory \033[0m" > text-control.txt
Ligne 276 ⟶ 271 :
#T echo "Inkey = $Inkey"
if [ "$Inkey" != 'y' ]; then echo " Inkey is not yes, or time out after 60 sec, exit from $0"; exit 0;fi
./#O test header.inc.sh -in test--tmode
 
#T test echo "Command ./header.inc.sh in- test-mode-t to verify environnement variables"
echo " in test mode with first param empty"
echo "Command ./header.inc.sh - --t to verify environnement variables"
./header.inc.sh - --t
echo " in test mode with first param empty"
echo;echo " wait for 2 sec"
./header.inc.sh - --t
sleep 5; echo "----"
echo;echo " wait for 2 sec"
#TO testTest with first param empty
sleep 5; echo "----"
echo "Command ./header.inc.sh - --t to verify environnementwithout variablesparameter"
 
./header.inc.sh
#T test with first param empty
echo;echo " wait for 2 sec"
echo "Command ./header.inc.sh without parameter"
sleep 2; echo "----"
./header.inc.sh
#TO Test, all with option --t
echo;echo " wait for 2 sec"
sleep 2; echo " All tests whith parameter ----t"
#PO List fullurllocal books for tests
 
#T Test, all with option --t
echo " All tests whith parameter --t"
#P List fullurl books for tests
Inkey=1
for i in 'seq 1 9'
Ligne 309 ⟶ 300 :
elif [ "$Inkey" = "8" ]; then ./header.inc.sh Tests_de_la_capacité_des_batteries_d%27accumulateurs
elif [ "$Inkey" = "9" ]; then ./header.inc.sh LivreTest --t
else echo "$inkey fulllocal url of site not found"; exit 0
fi
done