Skip to content

Commit

Permalink
improves tests
Browse files Browse the repository at this point in the history
  • Loading branch information
WolfgangFahl committed Feb 24, 2024
1 parent a464c62 commit e0fa8db
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
8 changes: 6 additions & 2 deletions ceurws/ceur_ws.py
Original file line number Diff line number Diff line change
Expand Up @@ -382,8 +382,12 @@ def update(self,parser_config:ParserConfig):
self.update_or_recreate(parser_config)

def set_down_to_volume(self,parser_config):
max_vol=self.volumes[len(self.volumes)-1]
parser_config.down_to_volume=max_vol.number+1
volumeCount=len(self.volumes)
if volumeCount>0:
max_vol=self.volumes[-1]
parser_config.down_to_volume=max_vol.number+1
else:
pass

def recreate(self,parser_config:ParserConfig):
"""
Expand Down
4 changes: 2 additions & 2 deletions ceurws/wikidatasync.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,8 +173,8 @@ def getRecentlyAddedVolumeList(self) -> list:
self.prepareVolumeManager()
refreshVm = VolumeManager()
parser_config=ParserConfig()
refreshVm.set_down_to_volume(parser_config)
refreshVm.loadFromIndexHtml()
self.vm.set_down_to_volume(parser_config)
refreshVm.loadFromIndexHtml(parser_config=parser_config)
refreshVolumesByNumber, _duplicates = LOD.getLookup(
refreshVm.getList(), "number"
)
Expand Down

0 comments on commit e0fa8db

Please sign in to comment.