| #!/bin/sh |
| |
| |
| |
| |
| t_Log "Running $0 - testing lzop compression and decompression" |
| |
| if [ $centos_ver = 5 ] |
| then |
| t_Log "This is a C5 system. Skipping." |
| ret_val=0 |
| elif [ $(t_GetArch) = i686 ] |
| then |
| t_Log "Package not available in i386 architecture. Skipping" |
| ret_val=0 |
| else |
| FILE1=/tmp/testfile.txt |
| FILE2=/tmp/testfile.lzo |
| |
| echo 'CentOS' > ${FILE1} |
| |
| |
| lzop -9 ${FILE1} -o ${FILE2} |
| /bin/rm ${FILE1} |
| |
| lzop -d ${FILE2} -o ${FILE1} |
| /bin/rm ${FILE2} |
| |
| |
| grep -q 'CentOS' ${FILE1} |
| ret_val=$? |
| |
| |
| /bin/rm ${FILE1} |
| fi |
| |
| t_CheckExitStatus $ret_val |