adding test CountryCountsByClickedBatchcodeProviderTest.test_getCityCountsByClickedBatchcode()

This commit is contained in:
frankknoll
2023-09-30 16:56:10 +02:00
parent ca2fe187f9
commit 26ebf43d5d
3 changed files with 48 additions and 1 deletions

View File

@@ -15,3 +15,19 @@ class CountryCountsByClickedBatchcodeProvider:
inplace = True)
exploration.set_index('COUNTRY', append = True, inplace = True)
return exploration
@staticmethod
def getCityCountsByClickedBatchcode(file):
exploration = pd.read_csv(file, index_col = 0, skiprows = [0, 1, 2, 3, 4, 5, 7])
exploration.index.name = 'VAX_LOT'
exploration.rename(
columns =
{
'Country': 'COUNTRY',
'Region': 'REGION',
'City': 'CITY',
'Event count': 'CITY_COUNT_BY_VAX_LOT'
},
inplace = True)
exploration.set_index(['COUNTRY', 'REGION', 'CITY'], append = True, inplace = True)
return exploration