model2tex1.gms : Test that model2tex produces a tex file

Description

Contributer: Clemens Westphal


Small Model of Type : GAMS


Category : GAMS Test library


Main file : model2tex1.gms

$title Test that model2tex produces a tex file (MODEL2TEX1,SEQ=678)
* Contributer: Clemens Westphal


$call gamslib -q trnsport
$if errorlevel 1 $abort could not retrieve trnsport
$call rm -f transport.tex

$call gams trnsport lo=%gams.lo% docFile=transport
$if errorlevel 1 $abort could not compile trnsport
* Skip testers (shanti), since Python is not available there
$if set nocomp $exit
$ifthen %system.filesys% == UNIX
* Check if PYTHON27 is available
$  ifthen.p not SetEnv PYTHON27
$    if %system.buildcode% == DEG $abort we should have python available
$    if %system.buildcode% == LEG $abort we should have python available
$    exit
$  endif.p
$  call %sysenv.PYTHON27% %gams.sysdir%model2tex.py transport > %system.nullfile%
$  if errorlevel 1 $abort could not run python
$else
$  call model2tex transport > %system.nullfile%
$  if errorlevel 1 $abort could not run model2tex
$endif
$if not exist transport.tex $abort no TeX file produced