EFForg / OpenWireless

The official home of the EFF OpenWireless Project
Other
732 stars 80 forks source link

FIXED #221 - Reenable wireless on limit adjustment #256

Closed akiellor closed 9 years ago

akiellor commented 9 years ago
akiellor commented 9 years ago

FIXES #221

Rangak commented 9 years ago

Thanks, Andrew. Will review this afternoon and merge.

Ranga

On Nov 30, 2014, at 11:34 PM, Andrew Kiellor notifications@github.com wrote:

Added FakeUci to make testing features which change config easier (works well with mock library) Refactored routerapi/update_setting is importable (for test) defines and runs a main and executes on name condition. Refactored routerapi/accumulate_bytes is importable (for test) defines and runs a main and executes on name condition. *extracted a script for running unit tests (if been using watch scripts/unit to continuously run) You can merge this Pull Request by running

git pull https://github.com/akiellor/OpenWireless reenable-wireless-on-limit-adjustment Or view, comment on, or merge it at:

https://github.com/EFForg/OpenWireless/pull/256

Commit Summary

Extracted script to run just unit tests Removed global params dictionary, introduced a main method, errors return a 500. Extracted FakeUci to separate class. Update network availablility upon bandwidth change. Enable wireless router when current_use is below limit. Should not restart wifi if disabled state does not change. File Changes

M routerapi/accumulate_bytes (19) A routerapi/accumulate_bytes.py (1) M routerapi/update_setting (110) M run-tests.sh (2) A scripts/unit (5) A test/accumulate_bytes_test.py (62) A test/fake_uci.py (14) A test/update_setting_test.py (21) Patch Links:

https://github.com/EFForg/OpenWireless/pull/256.patch https://github.com/EFForg/OpenWireless/pull/256.diff — Reply to this email directly or view it on GitHub.