-
Notifications
You must be signed in to change notification settings - Fork 96
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
Add basic testing for the tutorial #90
base: main
Are you sure you want to change the base?
Conversation
Conceptual_Guide/Part_7-iterative_scheduling/tests/test_iterative_scheduler.py
Show resolved
Hide resolved
import time | ||
import unittest | ||
|
||
from tritonserver import InferenceRequest, Model, Server |
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.
Nice use of in-process Python API for testing! This is super simple and clean 🚀
Conceptual_Guide/Part_7-iterative_scheduling/tests/test_iterative_scheduler.py
Outdated
Show resolved
Hide resolved
|
||
def test_max_tokens(self): | ||
self._infer_and_verify_request( | ||
32, |
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.
suggestion: make 32 a local constant,
suggestion: make the model name as a parameterized test:
https://realpython.com/pytest-python-testing/#parametrization-combining-tests
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.
parameterized doesn't work with unittest classes.
triton-inference-server/server#7176