Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
BIND
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
638
Issues
638
List
Boards
Labels
Service Desk
Milestones
Merge Requests
105
Merge Requests
105
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ISC Open Source Projects
BIND
Commits
8d96f3a2
Commit
8d96f3a2
authored
May 18, 2018
by
Mark Andrews
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix handling of failed tests
(cherry picked from commit
4283f955
)
parent
7d7f4daf
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
13 deletions
+13
-13
bin/tests/system/builtin/tests.sh
bin/tests/system/builtin/tests.sh
+13
-13
No files found.
bin/tests/system/builtin/tests.sh
View file @
8d96f3a2
...
...
@@ -25,7 +25,7 @@ grep "received control channel command 'reconfig'" ns1/named.run > /dev/null ||
grep
"reloading configuration succeeded"
ns1/named.run
>
/dev/null
||
ret
=
1
sleep
1
grep
"zone serial (0) unchanged."
ns1/named.run
>
/dev/null
&&
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
echo_i
"Checking that reloading empty zones is silent (
$n
)"
...
...
@@ -36,7 +36,7 @@ grep "received control channel command 'reload'" ns1/named.run > /dev/null || re
grep
"reloading configuration succeeded"
ns1/named.run
>
/dev/null
||
ret
=
1
sleep
1
grep
"zone serial (0) unchanged."
ns1/named.run
>
/dev/null
&&
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
VERSION
=
`
../../../../isc-config.sh
--version
|
cut
-d
=
-f
2
`
HOSTNAME
=
`
$FEATURETEST
--gethostname
`
...
...
@@ -46,42 +46,42 @@ ret=0
echo_i
"Checking that default version works for rndc (
$n
)"
$RNDCCMD
10.53.0.1 status
>
rndc.status.ns1.
$n
2>&1
grep
"^version: BIND
$VERSION
"
rndc.status.ns1.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
echo_i
"Checking that custom version works for rndc (
$n
)"
$RNDCCMD
10.53.0.3 status
>
rndc.status.ns3.
$n
2>&1
grep
"^version: BIND
$VERSION
${
DESCRIPTION
}${
DESCRIPTION
:+
}
<id:........*> (this is a test of version)"
rndc.status.ns3.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
echo_i
"Checking that default version works for query (
$n
)"
$DIG
$DIGOPTS
+short version.bind txt ch @10.53.0.1
>
dig.out.ns1.
$n
grep
"^
\"
$VERSION
\"
$"
dig.out.ns1.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
echo_i
"Checking that custom version works for query (
$n
)"
$DIG
$DIGOPTS
+short version.bind txt ch @10.53.0.3
>
dig.out.ns3.
$n
grep
"^
\"
this is a test of version
\"
$"
dig.out.ns3.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
echo_i
"Checking that default hostname works for query (
$n
)"
$DIG
$DIGOPTS
+short hostname.bind txt ch @10.53.0.1
>
dig.out.ns1.
$n
grep
"^
\"
$HOSTNAME
\"
$"
dig.out.ns1.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
echo_i
"Checking that custom hostname works for query (
$n
)"
$DIG
$DIGOPTS
+short hostname.bind txt ch @10.53.0.3
>
dig.out.ns3.
$n
grep
"^
\"
this.is.a.test.of.hostname
\"
$"
dig.out.ns3.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
...
...
@@ -89,35 +89,35 @@ echo_i "Checking that default server-id is none for query ($n)"
$DIG
$DIGOPTS
id.server txt ch @10.53.0.1
>
dig.out.ns1.
$n
grep
"status: NOERROR"
dig.out.ns1.
$n
>
/dev/null
||
ret
=
1
grep
"ANSWER: 0"
dig.out.ns1.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
echo_i
"Checking that server-id hostname works for query (
$n
)"
$DIG
$DIGOPTS
+short id.server txt ch @10.53.0.2
>
dig.out.ns2.
$n
grep
"^
\"
$HOSTNAME
\"
$"
dig.out.ns2.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
echo_i
"Checking that server-id hostname works for EDNS name server ID request (
$n
)"
$DIG
$DIGOPTS
+norec +nsid foo @10.53.0.2
>
dig.out.ns2.
$n
grep
"^; NSID: .* (
\"
$HOSTNAME
\"
)$"
dig.out.ns2.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
echo_i
"Checking that custom server-id works for query (
$n
)"
$DIG
$DIGOPTS
+short id.server txt ch @10.53.0.3
>
dig.out.ns3.
$n
grep
"^
\"
this.is.a.test.of.server-id
\"
$"
dig.out.ns3.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
n
=
`
expr
$n
+ 1
`
ret
=
0
echo_i
"Checking that custom server-id works for EDNS name server ID request (
$n
)"
$DIG
$DIGOPTS
+norec +nsid foo @10.53.0.3
>
dig.out.ns3.
$n
grep
"^; NSID: .* (
\"
this.is.a.test.of.server-id
\"
)$"
dig.out.ns3.
$n
>
/dev/null
||
ret
=
1
if
[
$ret
!=
0
]
;
then
echo_i
"failed
; status=
`
expr
$status
+
$ret
`
"
;
fi
if
[
$ret
!=
0
]
;
then
echo_i
"failed
"
;
status
=
`
expr
$status
+
$ret
`
;
fi
echo_i
"exit status:
$status
"
[
$status
-eq
0
]
||
exit
1
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment