replaced MenuPath class with namedtuple from collections module
added more unit tests