public static ValidateTarget <TSet> IsProperSubsetOf <TSet, TItem>([ValidatedNotNull] this ValidateTarget <TSet> target, IEnumerable <TItem> valueToCompare, Func <string> getErrorMessage = null)
            where TSet : ISet <TItem>
        {
            if (target.Value != null)
            {
                if (!target.Value.IsProperSubsetOf(valueToCompare))
                {
                    ExceptionFactory.ThrowException(target.Traits.GenericFailureExceptionType, getErrorMessage != null ? getErrorMessage.Invoke() : ErrorMessageFactory.ShouldBeProperSubsetOf(target));
                }
            }

            return(target);
        }