You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current tests has a lot of hardcode string assertion.
Two things that we can improve:
Move dummy functions to a conftest/, so when we need to retrieve the function body we can directly read the file as text, it's also easier to edit the test because the indention will not be weird indented string with """.
Refactor the function itself, so it returns data instead of the string of a function. We can then refactor our test to only test against the data. This should leave only 1 or 2 tests to assert with hardcoded string.
Assert the function arguments instead of the whole # Prepare necessary inputs for debugging.......
The text was updated successfully, but these errors were encountered:
The current tests has a lot of hardcode string assertion.
Two things that we can improve:
Move dummy functions to a conftest/, so when we need to retrieve the function body we can directly read the file as text, it's also easier to edit the test because the indention will not be weird indented string with
"""
.Refactor the function itself, so it returns data instead of the string of a function. We can then refactor our test to only test against the data. This should leave only 1 or 2 tests to assert with hardcoded string.
Assert the function arguments instead of the whole
# Prepare necessary inputs for debugging.......
The text was updated successfully, but these errors were encountered: