mirror of
git://git.code.sf.net/p/dhcpd-pools/code
synced 2025-12-18 00:37:01 +00:00
tests: improve coverage
Add error condition checks. Add lease file binding states. Check all output formats. Check leases file that is in mad order, cse all sorting methods when checking this. Use json output to check status classfications. Add cidr range checks. Add conf include and comment parsing input checks. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
parent
2849dde21b
commit
447241e6c3
33 changed files with 1059 additions and 51 deletions
198
tests/leases/shufled
Normal file
198
tests/leases/shufled
Normal file
|
|
@ -0,0 +1,198 @@
|
|||
lease 10.0.0.7 {
|
||||
}
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:07;
|
||||
hardware ethernet 00:00:00:00:00:10;
|
||||
lease 10.2.0.4 {
|
||||
lease 10.2.0.6 {
|
||||
lease 10.0.0.11 {
|
||||
binding state active;
|
||||
}
|
||||
hardware ethernet 00:00:00:00:00:03;
|
||||
lease 10.3.0.9 {
|
||||
}
|
||||
hardware ethernet 00:00:00:00:00:04;
|
||||
}
|
||||
binding state active;
|
||||
lease 10.1.0.7 {
|
||||
}
|
||||
}
|
||||
lease 10.1.0.9 {
|
||||
|
||||
hardware ethernet 00:00:00:00:00:07;
|
||||
hardware ethernet 00:00:00:00:00:01;
|
||||
binding state active;
|
||||
binding state active;
|
||||
}
|
||||
}
|
||||
}
|
||||
binding state active;
|
||||
lease 10.4.0.1 {
|
||||
}
|
||||
lease 10.0.0.0 {
|
||||
}
|
||||
hardware ethernet 00:00:00:00:00:10;
|
||||
}
|
||||
}
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:00;
|
||||
}
|
||||
}
|
||||
binding state active;
|
||||
}
|
||||
lease 10.3.0.2 {
|
||||
hardware ethernet 00:00:00:00:00:01;
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:02;
|
||||
binding state active;
|
||||
lease 10.1.0.3 {
|
||||
binding state active;
|
||||
}
|
||||
binding state active;
|
||||
}
|
||||
lease 10.1.0.1 {
|
||||
lease 10.3.0.8 {
|
||||
lease 10.2.0.1 {
|
||||
hardware ethernet 00:00:00:00:00:07;
|
||||
}
|
||||
}
|
||||
lease 10.4.0.0 {
|
||||
hardware ethernet 00:00:00:00:00:01;
|
||||
}
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:02;
|
||||
lease 10.0.0.10 {
|
||||
binding state active;
|
||||
}
|
||||
hardware ethernet 00:00:00:00:00:04;
|
||||
hardware ethernet 00:00:00:00:00:11;
|
||||
hardware ethernet 00:00:00:00:00:08;
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:08;
|
||||
binding state active;
|
||||
lease 10.2.0.5 {
|
||||
hardware ethernet 00:00:00:00:00:01;
|
||||
lease 10.1.0.8 {
|
||||
|
||||
lease 10.0.0.3 {
|
||||
binding state active;
|
||||
binding state active;
|
||||
lease 10.0.0.1 {
|
||||
lease 10.4.0.5 {
|
||||
hardware ethernet 00:00:00:00:00:06;
|
||||
|
||||
hardware ethernet 00:00:00:00:00:06;
|
||||
hardware ethernet 00:00:00:00:00:02;
|
||||
lease 10.2.0.3 {
|
||||
binding state active;
|
||||
lease 10.1.0.10 {
|
||||
binding state active;
|
||||
}
|
||||
}
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:03;
|
||||
}
|
||||
}
|
||||
hardware ethernet 00:00:00:00:00:05;
|
||||
lease 10.0.0.2 {
|
||||
}
|
||||
binding state active;
|
||||
}
|
||||
hardware ethernet 00:00:00:00:00:06;
|
||||
lease 10.3.0.6 {
|
||||
lease 10.0.0.8 {
|
||||
hardware ethernet 00:00:00:00:00:01;
|
||||
lease 10.4.0.3 {
|
||||
}
|
||||
}
|
||||
}
|
||||
binding state active;
|
||||
binding state active;
|
||||
lease 10.1.0.6 {
|
||||
lease 10.1.0.2 {
|
||||
hardware ethernet 00:00:00:00:00:05;
|
||||
binding state active;
|
||||
}
|
||||
}
|
||||
lease 10.2.0.7 {
|
||||
}
|
||||
}
|
||||
hardware ethernet 00:00:00:00:00:03;
|
||||
binding state active;
|
||||
|
||||
}
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:03;
|
||||
}
|
||||
lease 10.1.0.0 {
|
||||
hardware ethernet 00:00:00:00:00:04;
|
||||
binding state active;
|
||||
}
|
||||
lease 10.3.0.1 {
|
||||
lease 10.2.0.2 {
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:09;
|
||||
}
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:00;
|
||||
binding state active;
|
||||
lease 10.0.0.6 {
|
||||
hardware ethernet 00:00:00:00:00:02;
|
||||
binding state active;
|
||||
}
|
||||
binding state active;
|
||||
}
|
||||
lease 10.3.0.0 {
|
||||
lease 10.0.0.9 {
|
||||
binding state active;
|
||||
lease 10.0.0.4 {
|
||||
hardware ethernet 00:00:00:00:00:08;
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:07;
|
||||
hardware ethernet 00:00:00:00:00:00;
|
||||
binding state active;
|
||||
lease 10.1.0.4 {
|
||||
lease 10.4.0.2 {
|
||||
binding state active;
|
||||
}
|
||||
}
|
||||
lease 10.3.0.4 {
|
||||
hardware ethernet 00:00:00:00:00:05;
|
||||
hardware ethernet 00:00:00:00:00:05;
|
||||
binding state active;
|
||||
binding state active;
|
||||
lease 10.0.0.5 {
|
||||
hardware ethernet 00:00:00:00:00:04;
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:02;
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:09;
|
||||
hardware ethernet 00:00:00:00:00:08;
|
||||
lease 10.2.0.8 {
|
||||
}
|
||||
binding state active;
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:06;
|
||||
hardware ethernet 00:00:00:00:00:00;
|
||||
lease 10.3.0.7 {
|
||||
lease 10.4.0.4 {
|
||||
}
|
||||
hardware ethernet 00:00:00:00:00:04;
|
||||
}
|
||||
binding state active;
|
||||
lease 10.3.0.3 {
|
||||
hardware ethernet 00:00:00:00:00:03;
|
||||
lease 10.2.0.0 {
|
||||
binding state active;
|
||||
binding state active;
|
||||
hardware ethernet 00:00:00:00:00:05;
|
||||
|
||||
binding state active;
|
||||
}
|
||||
hardware ethernet 00:00:00:00:00:00;
|
||||
binding state active;
|
||||
lease 10.1.0.5 {
|
||||
hardware ethernet 00:00:00:00:00:09;
|
||||
lease 10.3.0.5 {
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue