Skip to content

Commit

Permalink
Increase test coverage
Browse files Browse the repository at this point in the history
Signed-off-by: Pavol Loffay <[email protected]>
  • Loading branch information
pavolloffay committed Oct 30, 2017
1 parent cfa2376 commit 84b75ff
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions cmd/query/app/static_handler_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ func TestDefaultStaticAssetsRoot(t *testing.T) {
assert.Nil(t, err)
}

func TestNotExistingUiConfig(t *testing.T) {
handler, err := NewStaticAssetsHandler("/foo/bar", "")
assert.Equal(t, "Cannot read UI static assets: open /foo/bar/index.html: no such file or directory", err.Error())
assert.Nil(t, handler)
}

func TestRegisterRoutesHandler(t *testing.T) {
r := mux.NewRouter()
handler, err := NewStaticAssetsHandler("fixture/", "")
Expand Down

0 comments on commit 84b75ff

Please sign in to comment.