File mttroot/mtt/bin/mtt_check_sese artifact 4337a95ac3 part of check-in 4e19f6168e


#! /bin/sh
## This script tests the sese generation by comparing the 
## dae files generated by the conventional approach
## Copyright (C) 2003 by Peter J. Gawthrop

sys=$1

## Correct dae file.
rm -vf ${sys}_ese.r MTT_work/${sys}_ese.r
mtt -q ${sys} dae r
mv -v ${sys}_dae.r ${sys}_dae.r_CORRECT

## sese file   
rm -vf ${sys}_sese.r MTT_work/${sys}_sese.r
mtt -q ${sys} sese r

## Create the dae file from the sese file 
cp -v ${sys}_sese.r ${sys}_ese.r
mtt -q ${sys} dae r

## And test
diff ${sys}_dae.r ${sys}_dae.r_CORRECT > mtt_diffs

## Result
if [ "$?" = "0" ]; then
    echo "****** dae files are the same ******"
else
    echo "****** dae files are different ******"
    cat mtt_diffs
fi


MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]