core: hide registerHandler (#964)

* core: hide registerHandler

Remove RegisterHandler and just make it implicit when we look at the
handler compilation step.

* Rename GetHandler to just Handler

Update callers and make auto check Hander in OnStartup.

* Up test coverage in erratic

* up test coverage
This commit is contained in:
Miek Gieben
2017-08-22 14:21:42 +01:00
committed by GitHub
parent 65009b5578
commit 8931ede142
11 changed files with 41 additions and 45 deletions

View File

@@ -18,6 +18,7 @@ func TestPrometheusParse(t *testing.T) {
// fails
{`prometheus {}`, true, ""},
{`prometheus /foo`, true, ""},
{`prometheus a b c`, true, ""},
}
for i, test := range tests {
c := caddy.NewTestController("dns", test.input)