21 lines
379 B
Go
21 lines
379 B
Go
|
|
package query_test
|
||
|
|
|
||
|
|
import (
|
||
|
|
"queryorchestration/internal/serviceconfig/queue/query"
|
||
|
|
"testing"
|
||
|
|
|
||
|
|
"github.com/stretchr/testify/assert"
|
||
|
|
)
|
||
|
|
|
||
|
|
func TestGetQueryURL(t *testing.T) {
|
||
|
|
cfg := query.QueryConfig{}
|
||
|
|
|
||
|
|
name := cfg.GetQueryURL()
|
||
|
|
assert.Equal(t, "", name)
|
||
|
|
|
||
|
|
cfg.QueryURL = "name"
|
||
|
|
name = cfg.GetQueryURL()
|
||
|
|
assert.Equal(t, "name", name)
|
||
|
|
assert.Equal(t, cfg.QueryURL, name)
|
||
|
|
}
|