Skip to content

Commit

Permalink
Fix fmt
Browse files Browse the repository at this point in the history
Signed-off-by: Pavol Loffay <ploffay@redhat.com>
  • Loading branch information
pavolloffay committed Nov 15, 2017
1 parent 777503d commit 133da74
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
7 changes: 3 additions & 4 deletions plugin/storage/es/spanstore/reader_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -844,15 +844,14 @@ func TestSpanReader_buildTagQuery(t *testing.T) {
})
}


func TestSpanReader_GetEmptyIndex(t *testing.T) {
withSpanReader(func (r *spanReaderTest){
withSpanReader(func(r *spanReaderTest) {
mockSearchService(r).
Return(&elastic.SearchResult{}, nil)
mockMultiSearchService(r).
Return(&elastic.MultiSearchResult{
Responses: []*elastic.SearchResult{},
}, nil)
Responses: []*elastic.SearchResult{},
}, nil)

traceQuery := &spanstore.TraceQueryParameters{
ServiceName: serviceName,
Expand Down
12 changes: 6 additions & 6 deletions plugin/storage/es/spanstore/service_operation_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,27 +112,27 @@ func TestSpanReader_GetOperations(t *testing.T) {
}

func TestSpanReader_GetServicesEmptyIndex(t *testing.T) {
withSpanReader(func (r *spanReaderTest){
withSpanReader(func(r *spanReaderTest) {
mockSearchService(r).
Return(&elastic.SearchResult{}, nil)
mockMultiSearchService(r).
Return(&elastic.MultiSearchResult{
Responses: []*elastic.SearchResult{},
}, nil)
Responses: []*elastic.SearchResult{},
}, nil)
services, err := r.reader.GetServices()
require.NoError(t, err)
assert.Empty(t, services)
})
}

func TestSpanReader_GetOperationsEmptyIndex(t *testing.T) {
withSpanReader(func (r *spanReaderTest){
withSpanReader(func(r *spanReaderTest) {
mockSearchService(r).
Return(&elastic.SearchResult{}, nil)
mockMultiSearchService(r).
Return(&elastic.MultiSearchResult{
Responses: []*elastic.SearchResult{},
}, nil)
Responses: []*elastic.SearchResult{},
}, nil)
services, err := r.reader.GetOperations("foo")
require.NoError(t, err)
assert.Empty(t, services)
Expand Down

0 comments on commit 133da74

Please sign in to comment.