// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/test/test-bcf_set_variant_type.c
// Function: test_bcf_set_variant_type
static void test_bcf_set_variant_type(void)
{
    // Test SNVs
    bcf_variant_t var1;
    bcf_set_variant_type("A", "T", &var1);
    if ( var1.type != VCF_SNP)
    {
        error("A -> T was not detected as a SNP");
    }

    // Test INDEL
    bcf_variant_t var2a;
    bcf_set_variant_type("A", "AA", &var2a);
    if ( var2a.type != (VCF_INDEL|VCF_INS) )
    {
        error("A -> AA was not detected as an INDEL");
    }
    bcf_variant_t var2b;
    bcf_set_variant_type("AA", "A", &var2b);
    if ( var2b.type != (VCF_INDEL|VCF_DEL) )
    {
        error("AA -> A was not detected as a INDEL");
    }

    // Test breakends
    bcf_variant_t var3a;
    bcf_set_variant_type("N", "N]16:33625444]", &var3a);
    if ( var3a.type != VCF_BND)
    {
        error("N]16:33625444] was not detected as a breakend");
    }

    bcf_variant_t var3b;
    bcf_set_variant_type("N", "N[16:33625444[", &var3b);
    if (var3b.type != VCF_BND)
    {
        error("N[16:33625444[ was not detected as a breakend");
    }

    bcf_variant_t var3c;
    bcf_set_variant_type("N", "]16:33625444]N", &var3c);
    if ( var3c.type != VCF_BND)
    {
        error("]16:33625444]N was not detected as a breakend");
    }

    bcf_variant_t var3d;
    bcf_set_variant_type("N", "[16:33625444[N", &var3d);
    if ( var3d.type != VCF_BND)
    {
        error("[16:33625444[N was not detected as a breakend");
    }

    bcf_set_variant_type("T", "]chrB:123]AGTNNNNNCAT", &var3d);
    if ( var3d.type != VCF_BND)
    {
        error("]chrB:123]AGTNNNNNCAT was not detected as a breakend");
    }
    bcf_set_variant_type("C", "CAGTNNNNNCA[chrA:321[", &var3d);
    if ( var3d.type != VCF_BND)
    {
        error("CAGTNNNNNCA[chrA:321[ was not detected as a breakend");
    }


    // Test special reference alleles
    bcf_variant_t var4a;
    bcf_set_variant_type("A", "<NON_REF>", &var4a);
    if ( var4a.type != VCF_REF)
    {
        error("<NON_REF> was not detected as a special reference allele");
    }
    bcf_variant_t var4b;
    bcf_set_variant_type("A", "<*>", &var4b);
    if ( var4b.type != VCF_REF)
    {
        error("<*> was not detected as a special reference allele");
    }
    // Test MNP
    bcf_variant_t var5;
    bcf_set_variant_type("AA", "TT", &var5);
    if ( var5.type != VCF_MNP)
    {
        error("AA->TT was not detected as a MNP");
    }
    // Test Overlapping allele
    bcf_variant_t var6;
    bcf_set_variant_type("A", "*", &var6);
    if ( var6.type != VCF_OVERLAP)
    {
        error("A->* was not detected as an overlap");
    }
    // Test .
    bcf_variant_t var7;
    bcf_set_variant_type("A", ".", &var7);
    if ( var7.type != VCF_REF)
    {
        error("A->. was not detected as a special reference allele");
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
leaq 0xe8b90(%rip), %rdi     # 0x1052bf
leaq 0xe8cdc(%rip), %rsi     # 0x105412
leaq -0x8(%rbp), %rdx
callq 0x20e40
cmpl $0x1, -0x8(%rbp)
je 0x1c753
leaq 0xe8b51(%rip), %rdi     # 0x10529d
movb $0x0, %al
callq 0x1c620
leaq 0xe8b65(%rip), %rdi     # 0x1052bf
leaq 0xe8b5d(%rip), %rsi     # 0x1052be
leaq -0x10(%rbp), %rdx
callq 0x20e40
cmpl $0x44, -0x10(%rbp)
je 0x1c77e
leaq 0xe8b4a(%rip), %rdi     # 0x1052c1
movb $0x0, %al
callq 0x1c620
leaq 0xe8b39(%rip), %rdi     # 0x1052be
leaq 0xe8b33(%rip), %rsi     # 0x1052bf
leaq -0x18(%rbp), %rdx
callq 0x20e40
cmpl $0x84, -0x18(%rbp)
je 0x1c7ac
leaq 0xe8b41(%rip), %rdi     # 0x1052e6
movb $0x0, %al
callq 0x1c620
leaq 0xed283(%rip), %rdi     # 0x109a36
leaq 0xe8b50(%rip), %rsi     # 0x10530a
leaq -0x20(%rbp), %rdx
callq 0x20e40
cmpl $0x10, -0x20(%rbp)
je 0x1c7d7
leaq 0xe8b49(%rip), %rdi     # 0x105319
movb $0x0, %al
callq 0x1c620
leaq 0xed258(%rip), %rdi     # 0x109a36
leaq 0xe8b62(%rip), %rsi     # 0x105347
leaq -0x28(%rbp), %rdx
callq 0x20e40
cmpl $0x10, -0x28(%rbp)
je 0x1c802
leaq 0xe8b5b(%rip), %rdi     # 0x105356
movb $0x0, %al
callq 0x1c620
leaq 0xed22d(%rip), %rdi     # 0x109a36
leaq 0xe8b74(%rip), %rsi     # 0x105384
leaq -0x30(%rbp), %rdx
callq 0x20e40
cmpl $0x10, -0x30(%rbp)
je 0x1c82d
leaq 0xe8b6d(%rip), %rdi     # 0x105393
movb $0x0, %al
callq 0x1c620
leaq 0xed202(%rip), %rdi     # 0x109a36
leaq 0xe8b86(%rip), %rsi     # 0x1053c1
leaq -0x38(%rbp), %rdx
callq 0x20e40
cmpl $0x10, -0x38(%rbp)
je 0x1c858
leaq 0xe8b7f(%rip), %rdi     # 0x1053d0
movb $0x0, %al
callq 0x1c620
leaq 0xe8bb3(%rip), %rdi     # 0x105412
leaq 0xe8b98(%rip), %rsi     # 0x1053fe
leaq -0x38(%rbp), %rdx
callq 0x20e40
cmpl $0x10, -0x38(%rbp)
je 0x1c883
leaq 0xe8b98(%rip), %rdi     # 0x105414
movb $0x0, %al
callq 0x1c620
leaq 0xed070(%rip), %rdi     # 0x1098fa
leaq 0xe8bb8(%rip), %rsi     # 0x105449
leaq -0x38(%rbp), %rdx
callq 0x20e40
cmpl $0x10, -0x38(%rbp)
je 0x1c8ae
leaq 0xe8bb8(%rip), %rdi     # 0x10545f
movb $0x0, %al
callq 0x1c620
leaq 0xe8a0a(%rip), %rdi     # 0x1052bf
leaq 0xe89d7(%rip), %rsi     # 0x105293
leaq -0x40(%rbp), %rdx
callq 0x20e40
cmpl $0x0, -0x40(%rbp)
je 0x1c8d9
leaq 0xe8bc2(%rip), %rdi     # 0x105494
movb $0x0, %al
callq 0x1c620
leaq 0xe89df(%rip), %rdi     # 0x1052bf
leaq 0xe89a8(%rip), %rsi     # 0x10528f
leaq -0x48(%rbp), %rdx
callq 0x20e40
cmpl $0x0, -0x48(%rbp)
je 0x1c904
leaq 0xe8bd0(%rip), %rdi     # 0x1054cd
movb $0x0, %al
callq 0x1c620
leaq 0xe89b3(%rip), %rdi     # 0x1052be
leaq 0xe8bee(%rip), %rsi     # 0x105500
leaq -0x50(%rbp), %rdx
callq 0x20e40
cmpl $0x2, -0x50(%rbp)
je 0x1c92f
leaq 0xe8bdb(%rip), %rdi     # 0x105503
movb $0x0, %al
callq 0x1c620
leaq 0xe8989(%rip), %rdi     # 0x1052bf
leaq 0xecd7c(%rip), %rsi     # 0x1096b9
leaq -0x58(%rbp), %rdx
callq 0x20e40
cmpl $0x20, -0x58(%rbp)
je 0x1c95a
leaq 0xe8bd1(%rip), %rdi     # 0x105524
movb $0x0, %al
callq 0x1c620
leaq 0xe895e(%rip), %rdi     # 0x1052bf
leaq 0xe76d6(%rip), %rsi     # 0x10403e
leaq -0x60(%rbp), %rdx
callq 0x20e40
cmpl $0x0, -0x60(%rbp)
je 0x1c985
leaq 0xe8bca(%rip), %rdi     # 0x105548
movb $0x0, %al
callq 0x1c620
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax,%rax)