Fixed cardinality handling of EntityProperty and CollectionProperty, cardinality
was not properly established before, improved handling of empty search attributes,
added many tests for different combinations of related node search, property
search, filtering etc.