// File: /workspace/github_c_makefile_star2_O3/OpenKMIP[P]libkmip/tests/tests.c
// Function: test_init_protocol_version
int
test_init_protocol_version(TestTracker *tracker)
{
    TRACK_TEST(tracker);

    kmip_init_protocol_version(NULL, KMIP_1_0);

    ProtocolVersion pv = {0};

    if(pv.major != 0)
        TEST_FAILED(tracker, __func__, __LINE__);
    if(pv.minor != 0)
        TEST_FAILED(tracker, __func__, __LINE__);

    kmip_init_protocol_version(&pv, KMIP_1_0);

    if(pv.major != 1)
        TEST_FAILED(tracker, __func__, __LINE__);
    if(pv.minor != 0)
        TEST_FAILED(tracker, __func__, __LINE__);

    kmip_init_protocol_version(&pv, KMIP_1_1);

    if(pv.major != 1)
        TEST_FAILED(tracker, __func__, __LINE__);
    if(pv.minor != 1)
        TEST_FAILED(tracker, __func__, __LINE__);

    kmip_init_protocol_version(&pv, KMIP_1_2);

    if(pv.major != 1)
        TEST_FAILED(tracker, __func__, __LINE__);
    if(pv.minor != 2)
        TEST_FAILED(tracker, __func__, __LINE__);

    kmip_init_protocol_version(&pv, KMIP_1_3);

    if(pv.major != 1)
        TEST_FAILED(tracker, __func__, __LINE__);
    if(pv.minor != 3)
        TEST_FAILED(tracker, __func__, __LINE__);

    kmip_init_protocol_version(&pv, KMIP_1_4);

    if(pv.major != 1)
        TEST_FAILED(tracker, __func__, __LINE__);
    if(pv.minor != 4)
        TEST_FAILED(tracker, __func__, __LINE__);

    kmip_init_protocol_version(&pv, KMIP_2_0);

    if(pv.major != 2)
        TEST_FAILED(tracker, __func__, __LINE__);
    if(pv.minor != 0)
        TEST_FAILED(tracker, __func__, __LINE__);

    TEST_PASSED(tracker, __func__);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
incw (%rdi)
xorl %edi, %edi
xorl %esi, %esi
callq 0x1385a
leaq 0x8(%rsp), %r14
movq $0x0, (%r14)
movq %r14, %rdi
xorl %esi, %esi
callq 0x1385a
cmpl $0x1, (%r14)
jne 0x3111
cmpl $0x0, 0xc(%rsp)
je 0x3144
leaq 0x2a11f(%rip), %rdi     # 0x2d222
leaq 0x2a3cd(%rip), %rsi     # 0x2d4d7
movl $0x49e, %edx            # imm = 0x49E
jmp 0x3124
leaq 0x2a10a(%rip), %rdi     # 0x2d222
leaq 0x2a3b8(%rip), %rsi     # 0x2d4d7
movl $0x49c, %edx            # imm = 0x49C
xorl %eax, %eax
callq 0x1090
movl $0x1, %ebp
movl $0x2, %eax
incw (%rbx,%rax)
movl %ebp, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x8(%rsp), %r14
movl $0x1, %ebp
movq %r14, %rdi
movl $0x1, %esi
callq 0x1385a
cmpl $0x1, (%r14)
jne 0x3224
cmpl $0x1, 0xc(%rsp)
jne 0x323c
leaq 0x8(%rsp), %r14
movq %r14, %rdi
movl $0x2, %esi
callq 0x1385a
cmpl $0x1, (%r14)
jne 0x3254
cmpl $0x2, 0xc(%rsp)
jne 0x3269
leaq 0x8(%rsp), %r14
movq %r14, %rdi
movl $0x3, %esi
callq 0x1385a
cmpl $0x1, (%r14)
jne 0x327e
cmpl $0x3, 0xc(%rsp)
jne 0x3293
leaq 0x8(%rsp), %r14
movq %r14, %rdi
movl $0x4, %esi
callq 0x1385a
cmpl $0x1, (%r14)
jne 0x32a8
cmpl $0x4, 0xc(%rsp)
jne 0x32bd
leaq 0x8(%rsp), %r14
movq %r14, %rdi
movl $0x5, %esi
callq 0x1385a
cmpl $0x2, (%r14)
jne 0x32d2
cmpl $0x0, 0xc(%rsp)
je 0x32f1
leaq 0x2a00f(%rip), %rdi     # 0x2d222
leaq 0x2a2bd(%rip), %rsi     # 0x2d4d7
movl $0x4c1, %edx            # imm = 0x4C1
jmp 0x32e5
leaq 0x29ff7(%rip), %rdi     # 0x2d222
leaq 0x2a2a5(%rip), %rsi     # 0x2d4d7
movl $0x4a3, %edx            # imm = 0x4A3
jmp 0x32e5
leaq 0x29fdf(%rip), %rdi     # 0x2d222
leaq 0x2a28d(%rip), %rsi     # 0x2d4d7
movl $0x4a5, %edx            # imm = 0x4A5
jmp 0x32e5
leaq 0x29fc7(%rip), %rdi     # 0x2d222
leaq 0x2a275(%rip), %rsi     # 0x2d4d7
movl $0x4aa, %edx            # imm = 0x4AA
jmp 0x32e5
leaq 0x29fb2(%rip), %rdi     # 0x2d222
leaq 0x2a260(%rip), %rsi     # 0x2d4d7
movl $0x4ac, %edx            # imm = 0x4AC
jmp 0x32e5
leaq 0x29f9d(%rip), %rdi     # 0x2d222
leaq 0x2a24b(%rip), %rsi     # 0x2d4d7
movl $0x4b1, %edx            # imm = 0x4B1
jmp 0x32e5
leaq 0x29f88(%rip), %rdi     # 0x2d222
leaq 0x2a236(%rip), %rsi     # 0x2d4d7
movl $0x4b3, %edx            # imm = 0x4B3
jmp 0x32e5
leaq 0x29f73(%rip), %rdi     # 0x2d222
leaq 0x2a221(%rip), %rsi     # 0x2d4d7
movl $0x4b8, %edx            # imm = 0x4B8
jmp 0x32e5
leaq 0x29f5e(%rip), %rdi     # 0x2d222
leaq 0x2a20c(%rip), %rsi     # 0x2d4d7
movl $0x4ba, %edx            # imm = 0x4BA
jmp 0x32e5
leaq 0x29f49(%rip), %rdi     # 0x2d222
leaq 0x2a1f7(%rip), %rsi     # 0x2d4d7
movl $0x4bf, %edx            # imm = 0x4BF
xorl %eax, %eax
callq 0x1090
jmp 0x3130
leaq 0x29f1f(%rip), %rdi     # 0x2d217
leaq 0x2a1d8(%rip), %rsi     # 0x2d4d7
xorl %ebp, %ebp
xorl %eax, %eax
callq 0x1090
movl $0x4, %eax
jmp 0x3135