@@ -231,7 +231,7 @@ func TestHandler_remoteWrite(t *testing.T) {
231231 req := createRequest (t , createPrometheusRemoteWriteV2Protobuf (t ), true )
232232 resp := httptest .NewRecorder ()
233233 handler .ServeHTTP (resp , req )
234- assert .Equal (t , http .StatusOK , resp .Code )
234+ assert .Equal (t , http .StatusNoContent , resp .Code )
235235
236236 // test header value
237237 respHeader := resp .Header ()
@@ -258,7 +258,7 @@ func TestHandler_ContentTypeAndEncoding(t *testing.T) {
258258 "Content-Encoding" : "snappy" ,
259259 remoteWriteVersionHeader : "2.0.0" ,
260260 },
261- expectedCode : http .StatusOK ,
261+ expectedCode : http .StatusNoContent ,
262262 isV2 : true ,
263263 },
264264 {
@@ -321,7 +321,7 @@ func TestHandler_ContentTypeAndEncoding(t *testing.T) {
321321 "Content-Type" : appProtoV2ContentType ,
322322 remoteWriteVersionHeader : "2.0.0" ,
323323 },
324- expectedCode : http .StatusOK ,
324+ expectedCode : http .StatusNoContent ,
325325 isV2 : true ,
326326 },
327327 {
@@ -330,7 +330,7 @@ func TestHandler_ContentTypeAndEncoding(t *testing.T) {
330330 "Content-Type" : appProtoV2ContentType ,
331331 "Content-Encoding" : "snappy" ,
332332 },
333- expectedCode : http .StatusOK ,
333+ expectedCode : http .StatusNoContent ,
334334 isV2 : true ,
335335 },
336336 {
@@ -375,7 +375,7 @@ func TestHandler_cortexWriteRequest(t *testing.T) {
375375 req := createRequest (t , createCortexRemoteWriteV2Protobuf (t , false , cortexpb .API ), true )
376376 resp := httptest .NewRecorder ()
377377 handler .ServeHTTP (resp , req )
378- assert .Equal (t , 200 , resp .Code )
378+ assert .Equal (t , http . StatusNoContent , resp .Code )
379379 })
380380}
381381
0 commit comments