Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 578ece4

Browse filesBrowse files
author
Takashi Matsuo
authored
[jobs] chore: remove gcp-devrel-py-tools (GoogleCloudPlatform#3475)
1 parent 44580b3 commit 578ece4
Copy full SHA for 578ece4
Expand file treeCollapse file tree

9 files changed

+41
-26
lines changed

‎jobs/v3/api_client/auto_complete_sample_test.py

Copy file name to clipboardExpand all lines: jobs/v3/api_client/auto_complete_sample_test.py
+5-3Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import pytest
1616
import re
1717

18-
from gcp_devrel.testing import eventually_consistent
18+
import backoff
1919

2020
import auto_complete_sample
2121

@@ -28,8 +28,8 @@ def company_name():
2828

2929

3030
def test_auto_complete_sample(company_name, capsys):
31-
@eventually_consistent.call
32-
def _():
31+
@backoff.on_exception(backoff.expo, AssertionError, max_time=120)
32+
def eventually_consistent_test():
3333
auto_complete_sample.run_sample(company_name)
3434
out, _ = capsys.readouterr()
3535
expected = (
@@ -41,3 +41,5 @@ def _():
4141
'suggestion.*Software Engineer.*type.*JOB_TITLE.*\n'
4242
)
4343
assert re.search(expected, out)
44+
45+
eventually_consistent_test()

‎jobs/v3/api_client/commute_search_sample_test.py

Copy file name to clipboardExpand all lines: jobs/v3/api_client/commute_search_sample_test.py
+5-3Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import pytest
1616
import re
1717

18-
from gcp_devrel.testing import eventually_consistent
18+
import backoff
1919

2020
import commute_search_sample
2121

@@ -28,9 +28,11 @@ def company_name():
2828

2929

3030
def test_commute_search_sample(company_name, capsys):
31-
@eventually_consistent.call
32-
def _():
31+
@backoff.on_exception(backoff.expo, AssertionError, max_time=120)
32+
def eventually_consistent_test():
3333
commute_search_sample.run_sample(company_name)
3434
out, _ = capsys.readouterr()
3535
expected = ('.*matchingJobs.*1600 Amphitheatre Pkwy.*')
3636
assert re.search(expected, out)
37+
38+
eventually_consistent_test()

‎jobs/v3/api_client/custom_attribute_sample_test.py

Copy file name to clipboardExpand all lines: jobs/v3/api_client/custom_attribute_sample_test.py
+5-3Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import pytest
1616
import re
1717

18-
from gcp_devrel.testing import eventually_consistent
18+
import backoff
1919

2020
import custom_attribute_sample
2121

@@ -28,11 +28,13 @@ def create_data():
2828

2929

3030
def test_custom_attribute_sample(create_data, capsys):
31-
@eventually_consistent.call
32-
def _():
31+
@backoff.on_exception(backoff.expo, AssertionError, max_time=120)
32+
def eventually_consistent_test():
3333
custom_attribute_sample.run_sample()
3434
out, _ = capsys.readouterr()
3535
expected = ('.*matchingJobs.*job_with_custom_attributes.*\n'
3636
'.*matchingJobs.*job_with_custom_attributes.*\n'
3737
'.*matchingJobs.*job_with_custom_attributes.*\n')
3838
assert re.search(expected, out, re.DOTALL)
39+
40+
eventually_consistent_test()

‎jobs/v3/api_client/email_alert_search_sample_test.py

Copy file name to clipboardExpand all lines: jobs/v3/api_client/email_alert_search_sample_test.py
+5-3Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import pytest
1616
import re
1717

18-
from gcp_devrel.testing import eventually_consistent
18+
import backoff
1919

2020
import email_alert_search_sample
2121

@@ -28,9 +28,11 @@ def company_name():
2828

2929

3030
def test_email_alert_search_sample(company_name, capsys):
31-
@eventually_consistent.call
32-
def _():
31+
@backoff.on_exception(backoff.expo, AssertionError, max_time=120)
32+
def eventually_consistent_test():
3333
email_alert_search_sample.run_sample(company_name)
3434
out, _ = capsys.readouterr()
3535
expected = ('.*matchingJobs.*')
3636
assert re.search(expected, out)
37+
38+
eventually_consistent_test()

‎jobs/v3/api_client/featured_job_search_sample_test.py

Copy file name to clipboardExpand all lines: jobs/v3/api_client/featured_job_search_sample_test.py
+5-3Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import pytest
1616
import re
1717

18-
from gcp_devrel.testing import eventually_consistent
18+
import backoff
1919

2020
import featured_job_search_sample
2121

@@ -28,9 +28,11 @@ def company_name():
2828

2929

3030
def test_featured_job_search_sample(company_name, capsys):
31-
@eventually_consistent.call
32-
def _():
31+
@backoff.on_exception(backoff.expo, AssertionError, max_time=120)
32+
def eventually_consistent_test():
3333
featured_job_search_sample.run_sample(company_name)
3434
out, _ = capsys.readouterr()
3535
expected = ('.*matchingJobs.*')
3636
assert re.search(expected, out)
37+
38+
eventually_consistent_test()

‎jobs/v3/api_client/general_search_sample_test.py

Copy file name to clipboardExpand all lines: jobs/v3/api_client/general_search_sample_test.py
+5-3Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import pytest
1616
import re
1717

18-
from gcp_devrel.testing import eventually_consistent
18+
import backoff
1919

2020
import general_search_sample
2121

@@ -28,8 +28,8 @@ def company_and_job():
2828

2929

3030
def test_general_search_sample(company_and_job, capsys):
31-
@eventually_consistent.call
32-
def _():
31+
@backoff.on_exception(backoff.expo, AssertionError, max_time=120)
32+
def eventually_consistent_test():
3333
general_search_sample.run_sample(
3434
company_and_job[0], company_and_job[1])
3535
out, _ = capsys.readouterr()
@@ -41,3 +41,5 @@ def _():
4141
'.*matchingJobs.*\n'
4242
'.*matchingJobs.*\n')
4343
assert re.search(expected, out, re.DOTALL)
44+
45+
eventually_consistent_test()

‎jobs/v3/api_client/histogram_sample_test.py

Copy file name to clipboardExpand all lines: jobs/v3/api_client/histogram_sample_test.py
+5-3Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import pytest
1616
import re
1717

18-
from gcp_devrel.testing import eventually_consistent
18+
import backoff
1919

2020
import histogram_sample
2121

@@ -28,9 +28,11 @@ def company_name():
2828

2929

3030
def test_histogram_sample(company_name, capsys):
31-
@eventually_consistent.call
32-
def _():
31+
@backoff.on_exception(backoff.expo, AssertionError, max_time=120)
32+
def eventually_consistent_test():
3333
histogram_sample.run_sample(company_name)
3434
out, _ = capsys.readouterr()
3535
assert re.search('COMPANY_ID', out)
3636
assert re.search('someFieldName1', out)
37+
38+
eventually_consistent_test()

‎jobs/v3/api_client/location_search_sample_test.py

Copy file name to clipboardExpand all lines: jobs/v3/api_client/location_search_sample_test.py
+5-3Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import pytest
1616
import re
1717

18-
from gcp_devrel.testing import eventually_consistent
18+
import backoff
1919

2020
import location_search_sample
2121

@@ -28,8 +28,8 @@ def company_name():
2828

2929

3030
def test_location_search_sample(company_name, capsys):
31-
@eventually_consistent.call
32-
def _():
31+
@backoff.on_exception(backoff.expo, AssertionError, max_time=120)
32+
def eventually_consistent_test():
3333
location_search_sample.run_sample(company_name)
3434
out, _ = capsys.readouterr()
3535
expected = ('.*locationFilters.*\n'
@@ -44,3 +44,5 @@ def _():
4444
'.*matchingJobs.*\n'
4545
'.*matchingJobs.*\n')
4646
assert re.search(expected, out, re.DOTALL)
47+
48+
eventually_consistent_test()
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1+
backoff==1.10.0
12
pytest==5.3.2
2-
google-cloud-core
3-
gcp-devrel-py-tools==0.0.16
43
flaky==3.6.1

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.