Skip to content

Commit

Permalink
Unit tests added to cover for single/multi-asic.
Browse files Browse the repository at this point in the history
  • Loading branch information
judyjoseph committed Nov 8, 2020
1 parent 6780945 commit b0d190e
Show file tree
Hide file tree
Showing 8 changed files with 1,295 additions and 3 deletions.
4 changes: 2 additions & 2 deletions crm/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,10 +113,9 @@ def get_acl_table_resources(self):
"""
# Retrieve all ACL table keys from CRM:ACL_TABLE_STATS
crm_acl_keys = self.db.keys(self.db.COUNTERS_DB, 'CRM:ACL_TABLE_STATS*')
data = []

for key in crm_acl_keys or [None]:
data = []

if key:
id = key.replace('CRM:ACL_TABLE_STATS:', '')

Expand All @@ -127,6 +126,7 @@ def get_acl_table_resources(self):
data.append([id, res, crm_stats['crm_stats_' + res + '_used'], crm_stats['crm_stats_' + res + '_available']])

return data

@multi_asic_util.run_on_multi_asic
def show_resources(self, resource):
"""
Expand Down
Loading

0 comments on commit b0d190e

Please sign in to comment.