Skip to content

Commit 5429ce7

Browse files
Merge pull request #2188 from VWS-Python/rm-break-tds-2
Try to actually run Test Database Summary tests - rather than quitting early
2 parents e7ca7d3 + 43e9864 commit 5429ce7

File tree

2 files changed

+14
-15
lines changed

2 files changed

+14
-15
lines changed

.github/workflows/ci.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,17 @@ jobs:
6262
- tests/mock_vws/test_content_length.py::TestIncorrect::test_not_integer
6363
- tests/mock_vws/test_content_length.py::TestIncorrect::test_too_large
6464
- tests/mock_vws/test_content_length.py::TestIncorrect::test_too_small
65-
- tests/mock_vws/test_database_summary.py
65+
- tests/mock_vws/test_database_summary.py::TestDatabaseSummary::test_success
66+
- tests/mock_vws/test_database_summary.py::TestDatabaseSummary::test_active_images
67+
- tests/mock_vws/test_database_summary.py::TestDatabaseSummary::test_failed_images
68+
- tests/mock_vws/test_database_summary.py::TestDatabaseSummary::test_inactive_images
69+
- tests/mock_vws/test_database_summary.py::TestDatabaseSummary::test_inactive_failed
70+
- tests/mock_vws/test_database_summary.py::TestDatabaseSummary::test_deleted
71+
- tests/mock_vws/test_database_summary.py::TestProcessingImages
72+
- tests/mock_vws/test_database_summary.py::TestQuotas
73+
- tests/mock_vws/test_database_summary.py::TestRecos
74+
- tests/mock_vws/test_database_summary.py::TestRequestUsage
75+
- tests/mock_vws/test_database_summary.py::TestInactiveProject
6676
- tests/mock_vws/test_date_header.py::TestFormat
6777
- tests/mock_vws/test_date_header.py::TestMissing
6878
- tests/mock_vws/test_date_header.py::TestSkewedTime::test_date_out_of_range_after

tests/mock_vws/test_database_summary.py

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def _wait_for_image_numbers(
3232
processing_images: int,
3333
) -> None:
3434
"""
35-
Wait up to 500 seconds (arbitrary, though we saw timeouts with 300 seconds)
35+
Wait up to 700 seconds (arbitrary, though we saw timeouts with 500 seconds)
3636
for the number of images in various categories to match the expected
3737
number.
3838
@@ -60,7 +60,7 @@ def _wait_for_image_numbers(
6060
"processing_images": processing_images,
6161
}
6262

63-
maximum_wait_seconds = 500
63+
maximum_wait_seconds = 700
6464
start_time = time.monotonic()
6565

6666
# If we wait for all requirements to match at the same time,
@@ -97,14 +97,6 @@ def _wait_for_image_numbers(
9797

9898
time.sleep(sleep_seconds)
9999

100-
# This break makes the entire test invalid.
101-
# However, we have found that without this Vuforia is flaky.
102-
# We have waited over 10 minutes for the summary to change and
103-
# that is not sustainable in a test suite.
104-
# That might be because we think some images will go into a particular
105-
# state but they don't.
106-
break
107-
108100

109101
@pytest.mark.usefixtures("verify_mock_vuforia")
110102
class TestDatabaseSummary:
@@ -132,10 +124,7 @@ def test_success(
132124
)
133125

134126
@staticmethod
135-
def test_active_images(
136-
vws_client: VWS,
137-
target_id: str,
138-
) -> None:
127+
def test_active_images(vws_client: VWS, target_id: str) -> None:
139128
"""
140129
The number of images in the active state is returned.
141130
"""

0 commit comments

Comments
 (0)