20 lines
312 B
Go
20 lines
312 B
Go
|
package postgres
|
||
|
|
||
|
import (
|
||
|
"testing"
|
||
|
)
|
||
|
|
||
|
func TestConnect(t *testing.T) {
|
||
|
return
|
||
|
}
|
||
|
|
||
|
func TestListSources(t *testing.T) {
|
||
|
defer Close()
|
||
|
sources, err := ListSources()
|
||
|
if err != nil {
|
||
|
t.Errorf("unexpected error : %s", err)
|
||
|
}
|
||
|
if len(sources) == 0 {
|
||
|
t.Errorf("no sources got from ListSources function")
|
||
|
}
|
||
|
}
|