mirror of
git://git.code.sf.net/p/dhcpd-pools/code
synced 2025-12-16 15:57:00 +00:00
add xml format check
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
parent
0d6c61d437
commit
c4e5ef6198
3 changed files with 35 additions and 0 deletions
|
|
@ -13,6 +13,7 @@ TESTS = \
|
|||
tests/complete \
|
||||
tests/empty \
|
||||
tests/full-json \
|
||||
tests/full-xml \
|
||||
tests/leading0 \
|
||||
tests/one-ip \
|
||||
tests/one-line \
|
||||
|
|
|
|||
21
tests/expected/same-twice-xml
Normal file
21
tests/expected/same-twice-xml
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
<dhcpstatus>
|
||||
<active_lease>
|
||||
<ip>10.0.0.5</ip>
|
||||
<macaddress>00:00:00:00:00:00</macaddress>
|
||||
</active_lease>
|
||||
<subnet>
|
||||
<location>All networks</location>
|
||||
<range>10.0.0.1 - 10.0.0.10</range>
|
||||
<defined>10</defined>
|
||||
<used>1</used>
|
||||
<touched>0</touched>
|
||||
<free>9</free>
|
||||
</subnet>
|
||||
<summary>
|
||||
<location>All networks</location>
|
||||
<defined>10</defined>
|
||||
<used>1</used>
|
||||
<touched>0</touched>
|
||||
<free>9</free>
|
||||
</summary>
|
||||
</dhcpstatus>
|
||||
13
tests/full-xml
Executable file
13
tests/full-xml
Executable file
|
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Minimal regression test suite.
|
||||
|
||||
if [ ! -d tests/outputs ]; then
|
||||
mkdir tests/outputs
|
||||
fi
|
||||
|
||||
dhcpd-pools -f X -c $top_srcdir/tests/confs/same-twice \
|
||||
-l $top_srcdir/tests/leases/same-twice \
|
||||
-o tests/outputs/same-twice-xml
|
||||
diff -u $top_srcdir/tests/expected/same-twice-xml tests/outputs/same-twice-xml
|
||||
exit $?
|
||||
Loading…
Add table
Add a link
Reference in a new issue