From 63e384d01c332b2ca8ee702a1c4128df98ba4ad1 Mon Sep 17 00:00:00 2001
From: Narcon Nicolas <nicolas.narcon@inrae.fr>
Date: Thu, 17 Mar 2022 09:37:08 +0100
Subject: [PATCH] REFAC: adapt inference unit test

---
 tests/inference_unittest.py | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)

diff --git a/tests/inference_unittest.py b/tests/inference_unittest.py
index 3af2b03..5f310c4 100644
--- a/tests/inference_unittest.py
+++ b/tests/inference_unittest.py
@@ -118,13 +118,11 @@ class InferenceTest(DecloudTest):
             self.get_path('baseline/PREPARE/S2_PREPARE/T31TEJ/SENTINEL2A_20201024-104859-766_L2A_T31TEJ_C_V2-2/')]
 
         outpath = '/tmp/reconstructed_w_preprocessor.tif'
-        crga_processor.main(["--il_s1before", *s1_tm1, "--il_s2before", *s2_tm1,
-                             "--il_s1", *s1_t, "--in_s2", s2_t,
-                             "--il_s1after", *s1_tp1, "--il_s2after", *s2_tp1,
-                             "--dem", self.get_path('baseline/PREPARE/DEM_PREPARE/T31TEJ.tif'),
-                             "--output", outpath, '--maxgap', '48',
-                             '--savedmodel', model_path])
-
+        crga_processor.crga_processor(il_s1before=s1_tm1, il_s2before=s2_tm1,
+                                      il_s1=s1_t, in_s2=s2_t,
+                                      il_s1after=s1_tp1, il_s2after=s2_tp1,
+                                      dem=self.get_path('baseline/PREPARE/DEM_PREPARE/T31TEJ.tif'),
+                                      output=outpath, maxgap=48, savedmodel=model_path)
 
         # Just a dummy test
         self.assertTrue(system.file_exists(outpath))
-- 
GitLab