-
Notifications
You must be signed in to change notification settings - Fork 53
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 (unit)tests #43
Comments
Didn't have much time last week, but got some tests running (PR follows today/tomorrow). for http I would need (@rgerganov please help):
|
for plain_coap I would need (@GeorgeSG please help) :
|
I'm pretty sure my device uses HTTP, not CoAP, it's AC2729/10. |
@GeorgeSG ok I think I got confused by this:
And 0.2.1 seems to use either coap or http not depending on this version number, I think I mixed that ... Someone here who runs the current master of airctrl with --protocol plain_coap? |
|
my model Id: AC3858/50 protocol coap version. [name] Name: Living Room |
|
After this modification:
I get this error, maybe I do something wrong:
|
Thanks for your contributions, my time was limited this week, but I'm nearly done.
And then you go on with:
Does your device support coap and plain_coap, so both commands work or is the first command a typo? Your problem with the permission error:
|
@spider7611
and not
? The following is a coap only output:
At least the "NanoProtect Filter Series 3" part wouldn't get translated this way, there would be no output at all for this line with plain_coap. At least code (beginning with py-air-control/pyairctrl/airctrl.py Line 234 in 121be67
|
I'm confused. Maybe changed the plain_coap and coap. Will try again later, sorry. |
No problem I was confused too :-) |
As there seems to be more refactoring in the near future since to coap-additions (#35) and library split (#34) I think we'll need some tests.
I'm not so deep into python-testing (since python is not my main profession), but I've looked into testing in coapthon and they seem to do it with coveralls which integrates nicely in travis (https://github.com/Tanganelli/CoAPthon3/blob/master/.travis.yml) and classes like unittest-class from the standard python library (https://github.com/Tanganelli/CoAPthon3/blob/master/coverage_test_advanced.py)
There might be other testing-frameworks though: https://realpython.com/python-testing/
Any inputs are welcome, I think we don't need to get overcomplicated, some decent (10-20) tests would cover most of our cases.
I would put some time into this.
The text was updated successfully, but these errors were encountered: