-
Notifications
You must be signed in to change notification settings - Fork 20
[Unit Test Failure]: ut_seattelib_tcptime.py #157
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
Comments
@karthikgvss will take a look at this issuel |
I see that tcp_time will set a mapping by calling time_register_method similarly, for ut_seattlelib_ntptime.py, time_interface.r2py has to be called instead of time.r2py as we are testing only ntp here. Also, port has to be determined by calling list(getresources()[0]["connport"])[0] instead of hard coding 12345. Please suggest. |
I find the interaction between these modules a little surprising. It is not immediately obvious that importing https://github.com/SeattleTestbed/seattlelib_v2/blob/master/tcp_time.r2py#L123-L124 What happens if we import both |
The
ut_seattlelib_tcptime.py
unit test fails with the following error:Unfortunately, the code seems to be testing an unexpected function. According to the comment in the docstring header, the
tcp_time_updatetime()
function should be tested, buttime_interface.time_updatetime(timeport)
is being called in the code. I expecttcp_time.tcp_time_updatetime()
to be the actual call.Likewise, the
ut_seattlelib_ntptime.py
unit test appears to be testing the wrong function, although its unit test does pass for the wrong reason.The text was updated successfully, but these errors were encountered: