@cryptotaxi247 / kubo / commits / f40fbb246

fix http test

verokarhu committed Sep 30, 2014 at 23:16 UTC f40fbb24622694734233d3439a10d40ebb4f2921
1 file changed +6 -6
server/http/http_test.go
+6 -6
@@ -24,9 +24,9 @@ type test struct {
24 func TestServeHTTP(t *testing.T) {
25 testhandler := &handler{&testIpfsHandler{}}
26 tests := []test{
27 - {"/", http.StatusInternalServerError, "", ""},
28 - {"/hash", http.StatusOK, "", "some fine data"},
29 - {"/hash2", http.StatusInternalServerError, "", ""},
27 + {"/ipfs/", http.StatusInternalServerError, "", ""},
28 + {"/ipfs/hash", http.StatusOK, "", "some fine data"},
29 + {"/ipfs/hash2", http.StatusInternalServerError, "", ""},
30 }
31
32 for _, test := range tests {
@@ -48,9 +48,9 @@ func TestServeHTTP(t *testing.T) {
48 func TestPostHandler(t *testing.T) {
49 testhandler := &handler{&testIpfsHandler{}}
50 tests := []test{
51 - {"/", http.StatusInternalServerError, "", ""},
52 - {"/", http.StatusInternalServerError, "something that causes an error in adding to DAG", ""},
53 - {"/", http.StatusCreated, "some fine data", "jSQBpNSebeYbPBjs1vp"},
51 + {"/ifps/", http.StatusInternalServerError, "", ""},
52 + {"/ipfs/", http.StatusInternalServerError, "something that causes an error in adding to DAG", ""},
53 + {"/ipfs/", http.StatusCreated, "some fine data", "jSQBpNSebeYbPBjs1vp"},
54 }
55
56 for _, test := range tests {