Skip to content

Commit 9bafc63

Browse files
[integ-tests] Relax test condition to allow EBS volume size reporting discrepancy
Signed-off-by: Hanwen <hanwenli@amazon.com>
1 parent 91d6730 commit 9bafc63

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

tests/integration-tests/tests/storage/test_shared_home.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,11 @@ def _check_shared_home(
135135
def _test_ebs_correctly_mounted(remote_command_executor, mount_dir, volume_size):
136136
logging.info(f"Testing ebs {mount_dir} is correctly mounted on login")
137137
result = remote_command_executor.run_remote_command(f"df -h | grep {mount_dir}")
138-
assert_that(result.stdout).matches(r"{size}G.*{mount_dir}".format(size=volume_size, mount_dir=mount_dir))
138+
assert_that(result.stdout).matches(
139+
r"({size}|{size_minus_one})G.*{mount_dir}".format(
140+
size=volume_size, size_minus_one=volume_size - 1, mount_dir=mount_dir
141+
)
142+
)
139143

140144
result = remote_command_executor.run_remote_command("cat /etc/fstab")
141145
assert_that(result.stdout).matches(r"{mount_dir}.*_netdev".format(mount_dir=mount_dir))

0 commit comments

Comments
 (0)