-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Re-enable doctest #5742
Re-enable doctest #5742
Conversation
dev_tools/docs/run_doctest.py
Outdated
excluded = [ | ||
'cirq-google/cirq_google/engine/client/', | ||
'cirq-google/cirq_google/cloud/', | ||
'cirq-google/cirq_google/api', | ||
] | ||
file_names = [f for f in file_names if not any(f.startswith(x) for x in excluded)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This avoids hard failure in cirq-google/cirq_google/optimizers/optimize_for_sycamore_test.py.
I guess we can skip doctesting docstrings in tests.
excluded = [ | |
'cirq-google/cirq_google/engine/client/', | |
'cirq-google/cirq_google/cloud/', | |
'cirq-google/cirq_google/api', | |
] | |
file_names = [f for f in file_names if not any(f.startswith(x) for x in excluded)] | |
excluded = [ | |
'cirq-google/cirq_google/engine/client/', | |
'cirq-google/cirq_google/cloud/', | |
'cirq-google/cirq_google/api/', | |
] | |
file_names = [f for f in file_names if not any(f.startswith(x) for x in excluded)] | |
file_names = [f for f in file_names if not f.endswith('_test.py')] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh yeah good, idea skipping tests. Added skipping.
dev_tools/docs/run_doctest.py
Outdated
@@ -161,6 +174,7 @@ def exec_tests( | |||
failed, attempted = 0, 0 | |||
error_messages = [] | |||
for test in tests: | |||
print(test.file_name) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please check if the printout should be in.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
definitely a left over print debug. removed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM if CI checks pass.
Automerge cancelled: A required status check is not present. Missing statuses: ['Pytest MacOS (3.7)', 'Pytest MacOS (3.8)', 'Pytest MacOS (3.9)', 'Pytest Windows (3.7)', 'Pytest Windows (3.8)', 'Pytest Windows (3.9)', 'Typescript lint check', 'Typescript tests', 'Typescript tests coverage'] |
dev_tools/docs/run_doctest.py
Outdated
@@ -230,17 +229,19 @@ def main(): | |||
'cirq-google/cirq_google/cloud/', | |||
'cirq-google/cirq_google/api', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To be on a safe side - let's replace api
--> api/
as for above paths.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
Getting this PR out for review.
There is a broken test due to a pending deprecation.
Fixes #5678