File tree Expand file tree Collapse file tree 5 files changed +83
-0
lines changed
regression-tests.nobackend/sort-records-with-prio Expand file tree Collapse file tree 5 files changed +83
-0
lines changed Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+
3
+ port=5501
4
+ rm -f pdns* .pid sort-records-with-prio/pdns.sqlite3
5
+
6
+ cat ../modules/gsqlite3backend/schema.sqlite3.sql | \
7
+ sqlite3 sort-records-with-prio/pdns.sqlite3
8
+
9
+ ../pdns/zone2sql --gsqlite --dnssec=no --named-conf=sort-records-with-prio/named.conf | \
10
+ sqlite3 sort-records-with-prio/pdns.sqlite3
11
+
12
+ $RUNWRAPPER ../pdns/pdns_server --daemon=no --local-port=$port --socket-dir=./ \
13
+ --no-shuffle --launch=gsqlite3 --gsqlite3-database=sort-records-with-prio/pdns.sqlite3 \
14
+ --send-root-referral --cache-ttl=60 --no-config --module-dir=../regression-tests/modules &
15
+
16
+ sleep 2
17
+
18
+ timeout 5 ../pdns/saxfr 127.0.0.1 $port example.org showdetails showflags | LC_ALL=C sort
19
+
20
+ kill $( cat pdns* .pid)
21
+ rm -f pdns* .pid sort-records-with-prio/pdns.sqlite3
Original file line number Diff line number Diff line change
1
+ Test if we correctly sort a bunch of records with priorities.
Original file line number Diff line number Diff line change
1
+ example.org. 3601 IN SOA dns1.exampledns.org. hostmaster.exampledns.org. 2015102301 43200 3600 604800 3601
2
+ example.org. 1800 IN MX 67 0vec4i2e.example.org.
3
+ example.org. 1800 IN MX 41 3gyvyh121.example.org.
4
+ example.org. 1800 IN MX 58 47g85qpc.example.org.
5
+ example.org. 1800 IN MX 60 5rtl4.example.org.
6
+ example.org. 1800 IN MX 1 6qys3.example.org.
7
+ example.org. 1800 IN MX 40 6wocbxd.example.org.
8
+ example.org. 1800 IN MX 59 7totbdrfl.example.org.
9
+ example.org. 1800 IN MX 64 9f4tja.example.org.
10
+ example.org. 1800 IN MX 66 9vkpekd.example.org.
11
+ example.org. 1800 IN MX 63 cphn494o.example.org.
12
+ example.org. 1800 IN MX 55 h90hhp.example.org.
13
+ example.org. 1800 IN MX 57 hcd16zwm.example.org.
14
+ example.org. 1800 IN MX 56 hpx58ao7.example.org.
15
+ example.org. 1800 IN MX 62 k20r61hi1.example.org.
16
+ example.org. 1800 IN MX 61 l06hv.example.org.
17
+ example.org. 1800 IN MX 65 sgwo0gq.example.org.
18
+ example.org. 1800 IN MX 54 vgo8ks5x.example.org.
19
+ example.org. 1800 IN NS dns1.exampledns.org.
20
+ example.org. 1800 IN NS dns2.exampledns.org.
21
+ example.org. 1800 IN NS dns3.exampledns.org.
22
+ example.org. 1800 IN NS dns4.exampledns.org.
23
+ example.org. 1800 IN NS dns5.exampledns.org.
Original file line number Diff line number Diff line change
1
+ example.org. 1800 IN MX 1 6qys3.example.org.
2
+ example.org. 1800 IN MX 40 6wocbxd.example.org.
3
+ example.org. 1800 IN MX 41 3gyvyh121.example.org.
4
+ example.org. 1800 IN MX 54 vgo8ks5x.example.org.
5
+ example.org. 1800 IN MX 55 h90hhp.example.org.
6
+ example.org. 1800 IN MX 56 hpx58ao7.example.org.
7
+ example.org. 1800 IN MX 57 hcd16zwm.example.org.
8
+ example.org. 1800 IN MX 58 47g85qpc.example.org.
9
+ example.org. 1800 IN MX 59 7totbdrfl.example.org.
10
+ example.org. 1800 IN MX 60 5rtl4.example.org.
11
+ example.org. 1800 IN MX 61 l06hv.example.org.
12
+ example.org. 1800 IN MX 62 k20r61hi1.example.org.
13
+ example.org. 1800 IN MX 63 cphn494o.example.org.
14
+ example.org. 1800 IN MX 64 9f4tja.example.org.
15
+ example.org. 1800 IN MX 65 sgwo0gq.example.org.
16
+ example.org. 1800 IN MX 66 9vkpekd.example.org.
17
+ example.org. 1800 IN MX 67 0vec4i2e.example.org.
18
+ example.org. 1800 IN NS dns1.exampledns.org.
19
+ example.org. 1800 IN NS dns2.exampledns.org.
20
+ example.org. 1800 IN NS dns3.exampledns.org.
21
+ example.org. 1800 IN NS dns4.exampledns.org.
22
+ example.org. 1800 IN NS dns5.exampledns.org.
23
+ example.org. 3601 IN SOA dns1.exampledns.org. hostmaster.exampledns.org. 2015102301 43200 3600 604800 3601
24
+ example.org. 3601 IN SOA dns1.exampledns.org. hostmaster.exampledns.org. 2015102301 43200 3600 604800 3601
Original file line number Diff line number Diff line change
1
+ options {
2
+ directory "./sort-records-with-prio";
3
+ recursion no;
4
+ listen-on port 5300 {
5
+ 127.0.0.1;
6
+ };
7
+ version "Meow!Meow!";
8
+ minimal-responses yes;
9
+ };
10
+
11
+ zone "example.org"{
12
+ type master;
13
+ file "./example.org";
14
+ };
You can’t perform that action at this time.
0 commit comments