Skip to content

Commit

Permalink
Add additional check to confirm that meta and meta spare are the same…
Browse files Browse the repository at this point in the history
… size

Signed-off-by: mulhern <[email protected]>
  • Loading branch information
mulkieran committed May 20, 2024
1 parent 6c43850 commit 161d3ad
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions testlib/infra.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,22 @@ def run_check(self):
current,
msg="previously written metadata and current metadata are not the same",
)

(thin_meta_size, thin_meta_spare_size) = [
sum(x[1] - x[0] for x in entries)
for entries in [
written["flex_devs"]["thin_meta_dev"],
written["flex_devs"]["thin_meta_dev_spare"],
]
]

self.assertEqual(
thin_meta_size,
thin_meta_spare_size,
"Total size of thin meta device is not equal to "
"total size of thin meta spare device.",
)

else:
current_message = (
"" if current_return_code == _OK else current_message
Expand Down

0 comments on commit 161d3ad

Please sign in to comment.