Skip to content

Commit

Permalink
remove importEtablissementHandler
Browse files Browse the repository at this point in the history
  • Loading branch information
Josquin Cornec committed Mar 26, 2024
1 parent c193c74 commit f1ca891
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 502 deletions.
12 changes: 2 additions & 10 deletions pkg/ops/imports/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ func ConfigureEndpoint(endpoint *gin.RouterGroup) {
endpoint.GET("/liste/:batchNumber/:algo", importPredictionsHandler)
endpoint.DELETE("/liste/:batchNumber/:algo", deletePredictionsHandler)
endpoint.GET("/liste/refresh", refreshVtablesHandler)
endpoint.GET("/full", importEtablissementHandler, importStockEtablissementsHandler, importUnitesLegalesHandler)
endpoint.GET("/full/:algo", importEtablissementHandler, importStockEtablissementsHandler, importUnitesLegalesHandler, importPredictionsHandler)
endpoint.GET("/full", importStockEtablissementsHandler, importUnitesLegalesHandler)
endpoint.GET("/full/:algo", importStockEtablissementsHandler, importUnitesLegalesHandler, importPredictionsHandler)
endpoint.GET("/bce", importBCEHandler)
endpoint.GET("/paydex", importPaydexHandler)
endpoint.GET("/urssaf", importUrssafHandler)
Expand All @@ -41,14 +41,6 @@ func importUnitesLegalesHandler(c *gin.Context) {
}
}

func importEtablissementHandler(c *gin.Context) {
err := importEtablissement()
if err != nil {
utils.AbortWithError(c, err)
return
}
}

func importPredictionsHandler(c *gin.Context) {
algo := c.Params.ByName("algo")
batchNumber := c.Params.ByName("batchNumber")
Expand Down
10 changes: 0 additions & 10 deletions pkg/ops/imports/import_integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,6 @@ func TestMain(m *testing.M) {
os.Exit(code)
}

func Test_importEntreprisesAndEtablissement(t *testing.T) {
test.FakeTime(t, tuTime)
//ass := assert.New(t)
err := test.Viperize(nil)
require.NoError(t, err)
//net.ParseIP()
err = importEtablissement()
require.NoError(t, err)
}

func Test_importPredictions_then_deletePredictions(t *testing.T) {
// GIVEN
batchNumber := "2304"
Expand Down
Loading

0 comments on commit f1ca891

Please sign in to comment.