summaryrefslogtreecommitdiffstats
path: root/tests/debian/01/run
blob: 6db7cf0eb11dc2dec55ad536f58c809ebfbea95b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/sh

set -e

cd $(dirname $0)

# The goal of this test is to check the distributed files (as debdiff)

save()
{
	[ ! -d tmp ] && mkdir tmp
}

restore()
{
	rm tmp/login_files tmp/passwd_files
	rmdir tmp
}

save

trap 'restore' 0

dpkg -L login | sort > tmp/login_files
dpkg -L passwd | sort > tmp/passwd_files

echo -n "Checking the login files..."
diff -u data/login_files tmp/login_files
echo "OK"
echo -n "Checking the passwd files..."
diff -u data/passwd_files tmp/passwd_files
echo OK