Makefile: test
This commit is contained in:
parent
bdb4a6b1f7
commit
fbfae1eccd
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -3,3 +3,4 @@
|
|||
*.xz
|
||||
*.lzma
|
||||
*.bz2
|
||||
testdir
|
||||
|
|
17
Makefile
17
Makefile
|
@ -10,3 +10,20 @@ logmanager.tar: logmanager logarchiver logcompressor logcleaner Makefile
|
|||
xz -c < $< > $@
|
||||
%.tar.bz2: %.tar
|
||||
bzip2 -c < $< > $@
|
||||
|
||||
testdir:
|
||||
mkdir $@
|
||||
|
||||
testdir/.lmtab: testdir
|
||||
echo $</ \*.log 60 > $@.tmp
|
||||
mv $@.tmp $@
|
||||
|
||||
testdir/.prepare: testdir testdir/.lmtab
|
||||
for f in `seq 1 10` ; do touch $</logfile$$f.log || exit 1 ; done
|
||||
touch $</no_log
|
||||
touch $</no.log.txt
|
||||
touch $@
|
||||
|
||||
test: testdir/.prepare testdir/.lmtab
|
||||
./logmanager -nc testdir/.lmtab
|
||||
./logmanager -Nc testdir/.lmtab
|
||||
|
|
Loading…
Reference in a new issue