public FeatureVariantEffects(IInterval feature, VariantType vt, IInterval variant, bool isSv) { _isSv = isSv; _completelyOverlaps = IntervalUtilities.Contains(variant.Start, variant.End, feature.Start, feature.End); _overlaps = feature.Overlaps(variant); _completelyWithin = variant.Start >= feature.Start && variant.End <= feature.End; _lossOrDeletion = vt == VariantType.copy_number_loss || vt == VariantType.deletion || vt == VariantType.copy_number_loss; _gainOrDuplication = vt == VariantType.copy_number_gain || vt == VariantType.duplication || vt == VariantType.tandem_duplication || vt == VariantType.copy_number_gain; _isInsertionDeletion = vt == VariantType.indel; _isInsertion = vt == VariantType.insertion; }
public void Contains_Theory(int start1, int end1, int start2, int end2, bool expectedResult) { var observedResult = IntervalUtilities.Contains(start1, end1, start2, end2); Assert.Equal(expectedResult, observedResult); }