chore: Refactor site to improve testing (#2014)

It was difficult to develop this package due to the
embed build tag being mandatory on the tests. The logic
to test doesn't require any embedded files.
This commit is contained in:
Kyle Carberry
2022-06-02 23:27:21 -05:00
committed by GitHub
parent 89dde21837
commit 61aacff444
6 changed files with 40 additions and 40 deletions

View File

@ -334,7 +334,7 @@ func New(options *Options) *API {
r.Get("/state", api.workspaceBuildState)
})
})
r.NotFound(site.DefaultHandler().ServeHTTP)
r.NotFound(site.Handler(site.FS()).ServeHTTP)
return api
}