Commit graph

7 commits

Author SHA1 Message Date
Tobi-wan Kenobi
716bafa90e [tests] Fix unit tests (at least on my system) 2016-12-10 19:45:13 +01:00
Tobi-wan Kenobi
2e2351a69e [tests] Mock Popen() in module tests 2016-12-10 19:35:38 +01:00
Tobi-wan Kenobi
a045962d00 [modules/nic] Re-enable NIC module
Re-add the NIC module with all its functionality (hopefully...).

This introduces a new concept: Instead of having separate queries for
critical and warning (which really are just another set of states), a
module can now return a list of states for each widget. All the state
information is then merged together into a single theme. So, for
instance, the NIC module can return a state saying "critical -
wlan-down", which applies the theme information for both "critical" and
"wlan-down".

see #23
2016-12-10 11:25:02 +01:00
Tobi-wan Kenobi
e59e969bdc [core] Refactor -> replace some getter/setter pairs with attributes
Remove some set_* methods and replace them with a simple attribute.

see #23
2016-12-09 11:49:59 +01:00
Tobi-wan Kenobi
0c7884d170 [all] pylint refinements
Improve code by bringing up the pylint score a bit.

see #23
2016-12-09 08:43:14 +01:00
Tobi-wan Kenobi
252260c249 [modules/datetime] Use parameter functionality to get format
Make the format string of the datetime module configurable using the new
parameter() method in the module.

Also, restructured the setting of the config information a bit so that
the parameter() method can be used in the constructor of a module.

see #23
2016-12-09 08:23:53 +01:00
Tobi-wan Kenobi
a7e756e015 [tests] Generic module tests
Add a helper function that lists all existing modules and modify the CPU
module test so that it now generically iterates all available modules
and tests their widgets.

see #23
2016-12-09 07:27:01 +01:00