Provide package http as a http.Server wrapper

This commit is contained in:
Harshavardhana
2015-01-13 17:34:44 -08:00
parent 0f66f0f5de
commit 6e84b1df97
2 changed files with 153 additions and 0 deletions

19
pkg/http/server_test.go Normal file
View File

@@ -0,0 +1,19 @@
package http
import (
. "gopkg.in/check.v1"
"testing"
)
type MySuite struct{}
var _ = Suite(&MySuite{})
func Test(t *testing.T) { TestingT(t) }
func (s *MySuite) TestHTTP(c *C) {
server := NewServer()
err := server.Listen("localhost:7000")
c.Assert(err, IsNil)
c.Assert(server.GetlistenURL(), Not(Equals), "")
}