Fix for NMS-6278 Part II - Fixing failing tests.

The applyThresholds method from ThresholdingSet should check the
required datasources used on the expression, not all the datasources
involved on the threshold (which includes the filter attributes).