mirror of https://github.com/0xERR0R/blocky.git
27 lines
457 B
Go
27 lines
457 B
Go
package cmd
|
|
|
|
import (
|
|
"time"
|
|
|
|
"github.com/0xERR0R/blocky/config"
|
|
|
|
. "github.com/onsi/ginkgo"
|
|
)
|
|
|
|
var _ = Describe("Serve command", func() {
|
|
When("Serve command is called", func() {
|
|
It("should start DNS server", func() {
|
|
config.GetConfig().BootstrapDNS = config.Upstream{
|
|
Net: "tcp+udp",
|
|
Host: "1.1.1.1",
|
|
Port: 53,
|
|
}
|
|
go startServer(newServeCommand(), []string{})
|
|
|
|
time.Sleep(100 * time.Millisecond)
|
|
|
|
done <- true
|
|
})
|
|
})
|
|
})
|