Skip to content

Commit

Permalink
Do not patch field. Addapt tests
Browse files Browse the repository at this point in the history
  • Loading branch information
davidmunoznovoa committed Dec 3, 2024
1 parent 220fcb4 commit 037e13f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
7 changes: 0 additions & 7 deletions mesures/cupsdat.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,13 +74,6 @@ def reader(self, file_path):
if row['fecha_hora_final_vigencia'] == ''
else datetime.strptime(row['fecha_hora_final_vigencia'], '%Y-%m-%d %H').strftime(DATE_MASK), axis=1)

# Patch indicador_tipo_medida if needed
if 'indicador_envio_medida' in self.columns:
df['indicador_envio_medida'] = df.apply(
lambda row: 'H'
if not row.get('indicador_envio_medida', False)
else row['indicador_envio_medida'], axis=1)

return df[self.columns]

def writer(self):
Expand Down
1 change: 1 addition & 0 deletions spec/generation_files_spec.py
Original file line number Diff line number Diff line change
Expand Up @@ -712,6 +712,7 @@ def get_sample_cupsdat_data():
def get_sample_cupsdat_data_isp_2024():
res = SampleData().get_sample_cupsdat_data()
res[0].update({'indicador_envio_medida': 'Q'})
res[1].update({'indicador_envio_medida': 'Q'})
return res

@staticmethod
Expand Down

0 comments on commit 037e13f

Please sign in to comment.