source: branches/stable/mondo/src/test/mktest @ 1054

Last change on this file since 1054 was 1054, checked in by bruno, 12 years ago
  • Backporting more trunk content into stable
  • Adding the test and lib directories
  • Preparing for l10n
  • Property svn:executable set to *
File size: 597 bytes
Line 
1#!/bin/bash
2#
3# $Id$
4#
5# test script for library functions
6#
7
8lib="../lib/mr_conf.c ../lib/mr_msg.c ../lib/mr_err.c ../lib/mr_mem.c"
9
10echo "Generating test-msg"
11gcc -O2 -g -I../common -I../include test-msg.c $lib -o test-msg
12echo "Generating test-string"
13gcc -O2 -g -I../common -I../include test-string.c ../lib/mr_str.c $lib -o test-string
14echo "Generating test-conf"
15gcc -O2 -g -I../common -I../include test-conf.c $lib -o test-conf
16
17for f in test-conf test-string test-msg; do
18    chmod 755 $f
19    ./$f > /tmp/$f.res
20    diff -q $f.res /tmp/$f.res
21    if [ $? -ne 0 ]; then
22        echo "$f test KO !!"
23    fi
24done
Note: See TracBrowser for help on using the repository browser.