Skip to content

Commit

Permalink
fix(generative_ai): update testcase (#10944)
Browse files Browse the repository at this point in the history
* fix(generative_ai): update testcase

* fix(generative_ai): add docs for test function

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

* fix(generative_ai): add docs for test function

* fix(generative_ai): code reformatting

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
msampathkumar and gcf-owl-bot[bot] authored Nov 21, 2023
1 parent a44aa59 commit 082336b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion generative_ai/code_completion_test_function_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,9 @@
@backoff.on_exception(backoff.expo, ResourceExhausted, max_time=10)
def test_code_completion_test_function() -> None:
content = code_completion_test_function.complete_test_function(temperature=0).text
assert "-> None:" in content
# every function def ends with `:`
assert content.startswith(":")
# test functions use `assert` for validations
assert "assert" in content
# test function should `reverse_string` at-least once
assert "reverse_string" in content

0 comments on commit 082336b

Please sign in to comment.