test: use isPermissionDenied

This commit is contained in:
Frank Schroeder 2017-05-10 08:56:16 +02:00 committed by Frank Schröder
parent 66bc2cbabc
commit a60f508880
1 changed files with 1 additions and 1 deletions

View File

@ -1707,7 +1707,7 @@ func TestAgent_Monitor_ACLDeny(t *testing.T) {
// Try without a token.
req, _ := http.NewRequest("GET", "/v1/agent/monitor", nil)
if _, err := srv.AgentMonitor(nil, req); err != errPermissionDenied {
if _, err := srv.AgentMonitor(nil, req); !isPermissionDenied(err) {
t.Fatalf("err: %v", err)
}