Search in sources :

Example 61 with SequenceVariation

use of org.nextprot.api.commons.bio.variation.prot.SequenceVariation in project nextprot-api by calipho-sib.

the class SequenceVariantHGVSFormatterTest method testFormatDuplicationSimpleCode3.

@Test
public void testFormatDuplicationSimpleCode3() throws Exception {
    SequenceVariation pm = new SequenceVariationImpl.FluentBuilding().selectAminoAcid(AminoAcidCode.CYSTEINE, 76).thenDuplicate().build();
    Assert.assertEquals("p.Cys76dup", format.format(pm, AminoAcidCode.CodeType.THREE_LETTER));
}
Also used : SequenceVariation(org.nextprot.api.commons.bio.variation.prot.SequenceVariation) SequenceVariationImpl(org.nextprot.api.commons.bio.variation.prot.impl.SequenceVariationImpl) Test(org.junit.Test)

Example 62 with SequenceVariation

use of org.nextprot.api.commons.bio.variation.prot.SequenceVariation in project nextprot-api by calipho-sib.

the class SequenceVariantHGVSFormatterTest method testFormatInitiationExtensionCode3.

@Test
public void testFormatInitiationExtensionCode3() throws Exception {
    SequenceVariation pm = new SequenceVariationImpl.FluentBuilding().selectAminoAcid(AminoAcidCode.METHIONINE, 1).thenInitiationExtension(-12, AminoAcidCode.VALINE).build();
    Assert.assertEquals("p.Met1Valext-12", format.format(pm, AminoAcidCode.CodeType.THREE_LETTER));
}
Also used : SequenceVariation(org.nextprot.api.commons.bio.variation.prot.SequenceVariation) SequenceVariationImpl(org.nextprot.api.commons.bio.variation.prot.impl.SequenceVariationImpl) Test(org.junit.Test)

Example 63 with SequenceVariation

use of org.nextprot.api.commons.bio.variation.prot.SequenceVariation in project nextprot-api by calipho-sib.

the class SequenceVariantHGVSFormatterTest method testFormatFrameshiftCode3.

@Test
public void testFormatFrameshiftCode3() throws Exception {
    SequenceVariation pm = new SequenceVariationImpl.FluentBuilding().selectAminoAcid(AminoAcidCode.METHIONINE, 682).thenFrameshift(AminoAcidCode.ALANINE, 2).build();
    Assert.assertEquals("p.Met682AlafsTer2", format.format(pm, AminoAcidCode.CodeType.THREE_LETTER));
}
Also used : SequenceVariation(org.nextprot.api.commons.bio.variation.prot.SequenceVariation) SequenceVariationImpl(org.nextprot.api.commons.bio.variation.prot.impl.SequenceVariationImpl) Test(org.junit.Test)

Example 64 with SequenceVariation

use of org.nextprot.api.commons.bio.variation.prot.SequenceVariation in project nextprot-api by calipho-sib.

the class SequenceVariantHGVSFormatterTest method testFormatDeletionMultiAasAndInsertion1.

@Test
public void testFormatDeletionMultiAasAndInsertion1() throws Exception {
    SequenceVariation pm = new SequenceVariationImpl.FluentBuilding().selectAminoAcidRange(AminoAcidCode.LEUCINE, 330, AminoAcidCode.ALANINE, 331).thenDeleteAndInsert(AminoAcidCode.PHENYLALANINE).build();
    Assert.assertEquals("p.L330_A331delinsF", format.format(pm));
}
Also used : SequenceVariation(org.nextprot.api.commons.bio.variation.prot.SequenceVariation) SequenceVariationImpl(org.nextprot.api.commons.bio.variation.prot.impl.SequenceVariationImpl) Test(org.junit.Test)

Example 65 with SequenceVariation

use of org.nextprot.api.commons.bio.variation.prot.SequenceVariation in project nextprot-api by calipho-sib.

the class SequenceVariantHGVSFormatterTest method testFormatDeletionMultiAndInsertionMultiCode3.

@Test
public void testFormatDeletionMultiAndInsertionMultiCode3() throws Exception {
    SequenceVariation pm = new SequenceVariationImpl.FluentBuilding().selectAminoAcidRange(AminoAcidCode.ASPARTIC_ACID, 419, AminoAcidCode.ARGININE, 420).thenDeleteAndInsert(AminoAcidCode.SERINE, AminoAcidCode.SERINE, AminoAcidCode.ASPARTIC_ACID, AminoAcidCode.GLYCINE).build();
    Assert.assertEquals("p.Asp419_Arg420delinsSerSerAspGly", format.format(pm, AminoAcidCode.CodeType.THREE_LETTER));
}
Also used : SequenceVariation(org.nextprot.api.commons.bio.variation.prot.SequenceVariation) SequenceVariationImpl(org.nextprot.api.commons.bio.variation.prot.impl.SequenceVariationImpl) Test(org.junit.Test)

Aggregations

SequenceVariation (org.nextprot.api.commons.bio.variation.prot.SequenceVariation)88 Test (org.junit.Test)85 SequenceVariationImpl (org.nextprot.api.commons.bio.variation.prot.impl.SequenceVariationImpl)31 AminoAcidCode (org.nextprot.api.commons.bio.AminoAcidCode)18 Substitution (org.nextprot.api.commons.bio.variation.prot.impl.seqchange.Substitution)6 Ignore (org.junit.Ignore)2 Frameshift (org.nextprot.api.commons.bio.variation.prot.impl.seqchange.Frameshift)2 Isoform (org.nextprot.api.core.domain.Isoform)2 GeneMasterCodonPosition (org.nextprot.api.core.utils.seqmap.GeneMasterCodonPosition)2 SequenceFeature (org.nextprot.api.isoform.mapper.domain.SequenceFeature)1 SingleFeatureQuery (org.nextprot.api.isoform.mapper.domain.SingleFeatureQuery)1