Skip to content

Commit

Permalink
increase timeout for restoring pvc snapshot
Browse files Browse the repository at this point in the history
Signed-off-by: vavuthu <vavuthu@redhat.com>
  • Loading branch information
vavuthu authored and fbalak committed Jun 14, 2024
1 parent 71a9e70 commit 350f51c
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 3 deletions.
6 changes: 6 additions & 0 deletions docs/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,12 @@ to the pytest.
* `--install-lvmo` - Deploy LVMCluster, will skip ODF deployment.
* `--lvmo-disks` - Number of disks to add to SNO deployment.
* `--lvmo-disks-size` - Size of disks to add to SNO deployment.
* `--disable-environment-checker` - Disable the leftover checks in existing flow.
* `--resource-checker` - This will identify the leftover which was created by test cases. This is
similar to environment-checker, only difference is resource-checker will track the resources
created during test case run whereas environment-checker will track all resources in
cluster irrespective of who created.
* `--kubeconfig` - Location of kubeconfig.
## Examples
Expand Down
6 changes: 3 additions & 3 deletions ocs_ci/framework/pytest_customization/ocscilib.py
Original file line number Diff line number Diff line change
Expand Up @@ -768,23 +768,23 @@ def pytest_runtest_makereport(item, call):
test_name = item.nodeid
# Write the failure information to a file
with open(
f'{ocsci_config.ENV_DATA["cluster_path"]}/failed_testcases.txt', "a"
f'{ocsci_config.ENV_DATA.get("cluster_path")}/failed_testcases.txt', "a"
) as file:
file.write(f"{test_name}\n")

if rep.passed and rep.when == "call":
test_name = item.nodeid
# Write the passed information to a file
with open(
f'{ocsci_config.ENV_DATA["cluster_path"]}/passed_testcases.txt', "a"
f'{ocsci_config.ENV_DATA.get("cluster_path")}/passed_testcases.txt', "a"
) as file:
file.write(f"{test_name}\n")

if rep.skipped:
test_name = item.nodeid
# Write the skipped information to a file
with open(
f'{ocsci_config.ENV_DATA["cluster_path"]}/skipped_testcases.txt', "a"
f'{ocsci_config.ENV_DATA.get("cluster_path")}/skipped_testcases.txt', "a"
) as file:
file.write(f"{test_name}\n")

Expand Down
3 changes: 3 additions & 0 deletions tests/functional/pv/pvc_clone/test_pvc_to_pvc_clone.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,7 @@ def test_pvc_to_pvc_rox_clone(
volume_mode=snapshot_obj.parent_volume_mode,
access_mode=constants.ACCESS_MODE_ROX,
status=constants.STATUS_BOUND,
timeout=300,
)
teardown_factory(restore_snapshot_obj)

Expand Down Expand Up @@ -333,6 +334,7 @@ def test_pvc_to_pvc_rox_shallow_vol_clone(
volume_mode=snapshot_obj.parent_volume_mode,
access_mode=constants.ACCESS_MODE_ROX,
status=constants.STATUS_BOUND,
timeout=300,
)
teardown_factory(restore_snapshot_obj)

Expand Down Expand Up @@ -470,6 +472,7 @@ def test_pvc_to_pvc_rox_shallow_vol_post_clone(
access_mode=constants.ACCESS_MODE_ROX,
status=constants.STATUS_BOUND,
restore_pvc_name="first-rwx-snapshot-restore-to-rox-mode-00",
timeout=300,
)
teardown_factory(restore_snapshot_obj)

Expand Down

0 comments on commit 350f51c

Please sign in to comment.