avocado.core.tree: Fix infinite recursion in TreeNode.__eq__

Original implementation compared self and then parent node. Parent
node again compared self and children => infinite recursion.

In the end we actually don't want to compare parents, because we care
about what is after this node. This implementation compares only Node
and children.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
avocado.core.tree: Fix TreeNode.iter_parents

Iterator should raise StopIteration, not return None.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
avocado.core.tree: Remove unnecessary branch from _create_from_yaml

Yaml creates pairs of items, thus isinstance(dict) branch should
not be possible (I hope).

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
avocado.core.tree: Use None instead of [] as defaults

defaults [] are not recommended, use None instead.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
avocado.multiplexer: Remove filter_only/filter_out

these functions were only used in unittests and were redundant to
tree.apply_filters().

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
avocado: Support for multiple multiplex yaml files

This patch adds support for multiple yaml files by merging the values
together. Merge overrides the nodes value and appends missing children
iteratively. It's deterministic AND order dependant (yaml1 yaml2 migh
not provide the same results as yaml2 yaml1!).

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
avocado.multiplexer: Rename create_variants_from_yaml to multiplex_yamls

create_variants_from_yaml is hideously long. Use multiplex_yamls instead.

Additionally change default values from lists to None.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
selftests..unit: Rewrite tree and multiplexer unittests

Instead of adjusting existing tests I rewrote them from scratch with
parallel execution in mind.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
avocado.core.tree: Stop using OrderedDict for values

Values doesn't need to be ordered, only node->child dependency order
matters.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
Merge pull request #297 from ldoktor/multiplexer

avocado.multiplexer: Support for multiple yaml files [v2]