Azure / azure-sdk-for-c

This repository is for active development of the Azure SDK for Embedded C. For consumers of the SDK we recommend visiting our versioned developer docs at https://azure.github.io/azure-sdk-for-c.
MIT License
224 stars 120 forks source link

ctest fails on Windows #912

Closed CIPop closed 4 years ago

CIPop commented 4 years ago

Describe the bug ctest fails on Windows

Exception or Stack Trace Add the exception log and stack trace if available

 ctest -V
UpdateCTestConfiguration  from :S:/c/build/DartConfiguration.tcl
UpdateCTestConfiguration  from :S:/c/build/DartConfiguration.tcl
Test project S:/c/build
Constructing a list of tests
Done constructing a list of tests
Updating test list for fixtures
Added 0 tests to meet fixture requirements
Checking test dependency graph...
Checking test dependency graph end
test 1
    Start 1: az_core_test

1: Test command: S:\c\build\sdk\tests\core\Debug\az_core_test.exe
1: Environment variables:
1:  PATH=;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\dotnet\;C:\Program Files\Git\cmd;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Users\crist\AppData\Local\Microsoft\WindowsApps;C:\Users\crist\AppData\Local\Programs\Microsoft VS Code\bin;S:\Tools;c:\Program Files\Sublime Text 3;c:\Program Files\CMake\bin;C:\Program Files (x86)\Nmap;C:\Users\crist\OneDrive\Documents\WindowsPowerShell\Modules\Pscx\3.3.2\Apps
1: Test timeout computed to be: 10000000
1: [==========] Running 1 test(s).
1: [ RUN      ] az_context_test
1: [       OK ] az_context_test
1: [==========] 1 test(s) run.
1: [  PASSED  ] 1 test(s).
1: [==========] Running 1 test(s).
1: [ RUN      ] test_credential_client_secret
1: [  ERROR   ] --- az_span_is_content_equal(expected_responses[i], response._internal.http_response)
1: [   LINE   ] --- S:\c\sdk\tests\core\test_az_credential_client_secret.c:93: error: Failure!
1: [  FAILED  ] test_credential_client_secret
1: [==========] 1 test(s) run.
1: [  PASSED  ] 0 test(s).
1: [  FAILED  ] 1 test(s), listed below:
1: [  FAILED  ] test_credential_client_secret
1:
1:  1 FAILED TEST(S)
1: [==========] Running 13 test(s).
1: [ RUN      ] test_http_request_removing_left_white_spaces
1: [       OK ] test_http_request_removing_left_white_spaces
1: [ RUN      ] test_http_request_header_validation
1: [       OK ] test_http_request_header_validation
1: [ RUN      ] test_http_request_header_validation_above_127
1: [       OK ] test_http_request_header_validation_above_127
1: [ RUN      ] test_http_response_append_null_response
1: [       OK ] test_http_response_append_null_response
1: [ RUN      ] test_http_request
1: [       OK ] test_http_request
1: [ RUN      ] test_http_response
1: [       OK ] test_http_response
1: [ RUN      ] test_http_request_header_validation_range
1: [       OK ] test_http_request_header_validation_range
1: [ RUN      ] test_http_response_header_validation
1: [       OK ] test_http_response_header_validation
1: [ RUN      ] test_http_response_header_validation_fail
1: [       OK ] test_http_response_header_validation_fail
1: [ RUN      ] test_http_response_header_validation_space
1: [       OK ] test_http_response_header_validation_space
1: [ RUN      ] test_http_response_append_overflow
1: [       OK ] test_http_response_append_overflow
1: [ RUN      ] test_http_response_append
1: [       OK ] test_http_response_append
1: [ RUN      ] test_http_response_append_overflow_on_second_call
1: [       OK ] test_http_response_append_overflow_on_second_call
1: [==========] 13 test(s) run.
1: [  PASSED  ] 13 test(s).
1: [==========] Running 6 test(s).
1: [ RUN      ] test_json_parser_init
1: [       OK ] test_json_parser_init
1: [ RUN      ] test_json_builder
1: [       OK ] test_json_builder
1: [ RUN      ] test_json_parser
1: [       OK ] test_json_parser
1: [ RUN      ] test_json_parser_invalid
1: [       OK ] test_json_parser_invalid
1: [ RUN      ] test_json_skip_children
1: [       OK ] test_json_skip_children
1: [ RUN      ] test_json_value
1: [       OK ] test_json_value
1: [==========] 6 test(s) run.
1: [  PASSED  ] 6 test(s).
1: [==========] Running 1 test(s).
1: [ RUN      ] test_az_log
1: [       OK ] test_az_log
1: [==========] 1 test(s) run.
1: [  PASSED  ] 1 test(s).
1: [==========] Running 1 test(s).
1: [ RUN      ] az_pipeline_test
1: [       OK ] az_pipeline_test
1: [==========] 1 test(s) run.
1: [  PASSED  ] 1 test(s).
1: [==========] Running 5 test(s).
1: [ RUN      ] test_az_http_pipeline_policy_retry
1: [  ERROR   ] --- %s() has remaining non-returned values.
1: S:\c\sdk\tests\core\test_az_policy.c:243: note: remaining item was declared here
1:
1: [  FAILED  ] test_az_http_pipeline_policy_retry
1: [ RUN      ] test_az_http_pipeline_policy_retry_with_header
1: [  ERROR   ] --- %s() has remaining non-returned values.
1: S:\c\sdk\tests\core\test_az_policy.c:283: note: remaining item was declared here
1:
1: [  FAILED  ] test_az_http_pipeline_policy_retry_with_header
1: [ RUN      ] test_az_http_pipeline_policy_retry_with_header_2
1: [  ERROR   ] --- %s() has remaining non-returned values.
1: S:\c\sdk\tests\core\test_az_policy.c:324: note: remaining item was declared here
1:
1: [  FAILED  ] test_az_http_pipeline_policy_retry_with_header_2
1: [ RUN      ] test_az_http_pipeline_policy_apiversion
1: [       OK ] test_az_http_pipeline_policy_apiversion
1: [ RUN      ] test_az_http_pipeline_policy_telemetry
1: [       OK ] test_az_http_pipeline_policy_telemetry
1: [==========] 5 test(s) run.
1: [  PASSED  ] 2 test(s).
1: [  FAILED  ] 3 test(s), listed below:
1: [  FAILED  ] test_az_http_pipeline_policy_retry
1: [  FAILED  ] test_az_http_pipeline_policy_retry_with_header
1: [  FAILED  ] test_az_http_pipeline_policy_retry_with_header_2
1:
1:  3 FAILED TEST(S)

To Reproduce Steps to reproduce the behavior: Windows + Powershell + Visual Studio 2019. Run ctest

Code Snippet Add the code snippet that causes the issue.

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Setup (please complete the following information):

Additional context Add any other context about the problem here.

Information Checklist Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report

ahsonkhan commented 4 years ago

I am unable to reproduce any test failure locally. I am surprised you are seeing such a failure because CI would (or at least should) have caught such issues.

I run the following command following https://github.com/Azure/azure-sdk-for-c#getting-started-using-the-sdk and all test pass (in VS developer prompt and in powershell):

cmake -DUNIT_TESTING=ON .. && cmake --build . && ctest -V

I wonder if there is something different between your dev machine setup and repo versus mine. Is your environment variables set correctly?

Are you using vcpkg (with latest version of cmocka/etc.), and can you try on a clean clone of the repo?

Some of the relevant environment variables on my setup: VCPKG_DEFAULT_TRIPLET=x64-windows-static VCPKG_ROOT=E:\GitHub\vcpkg cmocka_DIR=C:\Program Files (x86)\cmocka\CMake\cmocka

And the cmocka version I have locally is 1.1.5-1, from E:\GitHub\vcpkg\packages\cmocka_x64-windows-static\CONTROL

vhvb1989 commented 4 years ago

@CIPop is this on master? I have seen this on the ports branch that @RickWinter has on progress. Where are you seeing this?

This error is due to gcc linker is unable to override inline functions. There was a change on platform header to make az_platform_clock_msec() and az_platform_sleep_msec() INLINE functions and hence this functions can't be linked to a __wrap_fn() during link time.

cmocka defines functions like __wrap_az_platform_sleep_msec() and mocks the result values. But if the linker did not change the original function, then tests would run with platform implementation. When that happen, tests takes more time than the default timeout on cmocka.

CIPop commented 4 years ago

@vhvb1989 yes, this was master (left the exact commit id in the description). This is happening on Windows so no gcc in my case.

@ahsonkhan I use msbuild /m az.sln to build then ctest to get this error.

Your command doesn't work in Powershell:

cmake -DUNIT_TESTING=ON .. && cmake --build . && ctest -V
At line:1 char:28
+ cmake -DUNIT_TESTING=ON .. && cmake --build . && ctest -V
+                            ~~
The token '&&' is not a valid statement separator in this version.
At line:1 char:47
+ cmake -DUNIT_TESTING=ON .. && cmake --build . && ctest -V
+                                               ~~
The token '&&' is not a valid statement separator in this version.
    + CategoryInfo          : ParserError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : InvalidEndOfLine

Running each command separately worked for me too. I think the issue is that you're not actually running the tests that fail the same way (very concerning since UTs should always be deterministic).

Here's my cmake-gui config:

image

With this, the test fails consistently:

❯ cmake --build .
Microsoft (R) Build Engine version 16.6.0+5ff7b0c9e for .NET Framework
Copyright (C) Microsoft Corporation. All rights reserved.

  Checking Build System
  Building Custom Rule S:/c/sdk/src/azure/platform/CMakeLists.txt
  az_noplatform.c
  az_noplatform.vcxproj -> S:\c\build\sdk\src\azure\platform\Debug\az_noplatform.lib
  az_aad.c
  az_credential_client_secret.c
  az_credential_token.c
  az_context.c
  az_http_pipeline.c
  az_http_policy.c
  az_http_policy_logging.c
  az_http_policy_retry.c
  az_http_request.c
  az_http_response.c
  az_json_builder.c
  az_json_parser.c
  az_json_token.c
  az_log.c
  az_precondition.c
  az_span.c
  az_spinlock.c
  Compiling...
  Generating Code...
  az_core.vcxproj -> S:\c\build\sdk\src\azure\core\Debug\az_core.lib
  Building Custom Rule S:/c/sdk/src/azure/platform/CMakeLists.txt
  az_nohttp.c
  az_nohttp.vcxproj -> S:\c\build\sdk\src\azure\platform\Debug\az_nohttp.lib
  main.c
  test_az_context.c
  test_az_credential_client_secret.c
  test_az_http.c
  test_az_json.c
  test_az_logging.c
  test_az_pipeline.c
  test_az_policy.c
  test_az_span.c
  test_az_url_encode.c
  Compiling...
  Generating Code...
LINK : warning LNK4044: unrecognized option '/Wl,--wrap=az_platform_clock_msec'; ignored [S:\c\build\sdk\tests\core\az_core_test.vcxproj]
LINK : warning LNK4044: unrecognized option '/Wl,--wrap=az_http_client_send_request'; ignored [S:\c\build\sdk\tests\core\az_core_test.vcxproj]
LINK : warning LNK4044: unrecognized option '/Wl,--wrap=az_platform_clock_msec'; ignored [S:\c\build\sdk\tests\core\az_core_test.vcxproj]
LINK : warning LNK4044: unrecognized option '/Wl,--wrap=az_http_client_send_request'; ignored [S:\c\build\sdk\tests\core\az_core_test.vcxproj]
LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library [S:\c\build\sdk\tests\core\az_core_test.vcxproj]
  az_core_test.vcxproj -> S:\c\build\sdk\tests\core\Debug\az_core_test.exe
  Building Custom Rule S:/c/sdk/src/azure/platform/CMakeLists.txt
  az_curl.c
  az_curl.vcxproj -> S:\c\build\sdk\src\azure\platform\Debug\az_curl.lib
  az_iot_common.c
  az_iot_common.vcxproj -> S:\c\build\sdk\src\azure\iot\Debug\az_iot_common.lib
  main.c
  test_az_iot_common.c
  Compiling...
  Generating Code...
  az_iot_common_test.vcxproj -> S:\c\build\sdk\tests\iot\common\Debug\az_iot_common_test.exe
  az_iot_hub_client.c
  az_iot_hub_client_sas.c
  az_iot_hub_client_telemetry.c
  az_iot_hub_client_c2d.c
  az_iot_hub_client_twin.c
  az_iot_hub_client_methods.c
  Compiling...
  Generating Code...
  az_iot_hub.vcxproj -> S:\c\build\sdk\src\azure\iot\Debug\az_iot_hub.lib
  main.c
  test_az_iot_hub_client_sas.c
  test_az_iot_hub_client_telemetry.c
  test_az_iot_hub_client_c2d.c
  test_az_iot_hub_client.c
  test_az_iot_hub_client_twin.c
  test_az_iot_hub_client_methods.c
  Compiling...
  Generating Code...
  az_iot_hub_test.vcxproj -> S:\c\build\sdk\tests\iot\hub\Debug\az_iot_hub_test.exe
  az_iot_provisioning_client.c
  az_iot_provisioning_client_sas.c
  Compiling...
  Generating Code...
  az_iot_provisioning.vcxproj -> S:\c\build\sdk\src\azure\iot\Debug\az_iot_provisioning.lib
  main.c
  test_az_iot_provisioning_client.c
  test_az_iot_provisioning_client_sas.c
  test_az_iot_provisioning_client_parser.c
  Compiling...
  Generating Code...
  az_iot_provisioning_test.vcxproj -> S:\c\build\sdk\tests\iot\provisioning\Debug\az_iot_provisioning_test.exe
  az_storage_blobs_blob_client.c
  az_storage_blobs.vcxproj -> S:\c\build\sdk\src\azure\storage\Debug\az_storage_blobs.lib
  main.c
  az_storage_blobs_unit_tests.c
  Compiling...
  Generating Code...
LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library [S:\c\build\sdk\tests\storage\blobs\az_storage_blobs_test.vcxproj]
  az_storage_blobs_test.vcxproj -> S:\c\build\sdk\tests\storage\blobs\Debug\az_storage_blobs_test.exe
  Building Custom Rule S:/c/sdk/samples/storage/blobs/CMakeLists.txt
  blobs_client_example.c
LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library [S:\c\build\sdk\samples\storage\blobs\blobs_client_example.vcxproj]
  blobs_client_example.vcxproj -> S:\c\build\sdk\samples\storage\blobs\Debug\blobs_client_example.exe
  Building Custom Rule S:/c/sdk/samples/iot/hub/CMakeLists.txt
  paho_iot_hub_c2d_example.c
     Creating library S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_c2d_example.lib and object S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_c2d_example.exp
LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library [S:\c\build\sdk\samples\iot\hub\paho_iot_hub_c2d_example.vcxproj]
  paho_iot_hub_c2d_example.vcxproj -> S:\c\build\sdk\samples\iot\hub\Debug\paho_iot_hub_c2d_example.exe
  Building Custom Rule S:/c/sdk/samples/iot/hub/CMakeLists.txt
  paho_iot_hub_methods_example.c
     Creating library S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_methods_example.lib and object S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_methods_example.exp
LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library [S:\c\build\sdk\samples\iot\hub\paho_iot_hub_methods_example.vcxproj]
  paho_iot_hub_methods_example.vcxproj -> S:\c\build\sdk\samples\iot\hub\Debug\paho_iot_hub_methods_example.exe
  Building Custom Rule S:/c/sdk/samples/iot/hub/CMakeLists.txt
  paho_iot_hub_sas_telemetry_example.c
  sample_sas_utility.c
  Compiling...
  Generating Code...
     Creating library S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_sas_telemetry_example.lib and object S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_sas_telemetry_example.exp
LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library [S:\c\build\sdk\samples\iot\hub\paho_iot_hub_sas_telemetry_example.vcxproj]
  paho_iot_hub_sas_telemetry_example.vcxproj -> S:\c\build\sdk\samples\iot\hub\Debug\paho_iot_hub_sas_telemetry_example.exe
  Building Custom Rule S:/c/sdk/samples/iot/hub/CMakeLists.txt
  paho_iot_hub_telemetry_example.c
     Creating library S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_telemetry_example.lib and object S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_telemetry_example.exp
LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library [S:\c\build\sdk\samples\iot\hub\paho_iot_hub_telemetry_example.vcxproj]
  paho_iot_hub_telemetry_example.vcxproj -> S:\c\build\sdk\samples\iot\hub\Debug\paho_iot_hub_telemetry_example.exe
  Building Custom Rule S:/c/sdk/samples/iot/hub/CMakeLists.txt
  paho_iot_hub_twin_example.c
     Creating library S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_twin_example.lib and object S:/c/build/sdk/samples/iot/hub/Debug/paho_iot_hub_twin_example.exp
LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library [S:\c\build\sdk\samples\iot\hub\paho_iot_hub_twin_example.vcxproj]
  paho_iot_hub_twin_example.vcxproj -> S:\c\build\sdk\samples\iot\hub\Debug\paho_iot_hub_twin_example.exe
  Building Custom Rule S:/c/sdk/samples/iot/provisioning/CMakeLists.txt
  paho_iot_provisioning_example.c
     Creating library S:/c/build/sdk/samples/iot/provisioning/Debug/paho_iot_provisioning_example.lib and object S:/c/build/sdk/samples/iot/provisioning/Debug/paho_iot_provisioning_example.exp
LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library [S:\c\build\sdk\samples\iot\provisioning\paho_iot_provisioning_example.vcxproj]
  paho_iot_provisioning_example.vcxproj -> S:\c\build\sdk\samples\iot\provisioning\Debug\paho_iot_provisioning_example.exe
  Building Custom Rule S:/c/CMakeLists.txt
crist@QUARK  S:\c\build   master ≣                                                                                                                                                                                             [13:01]
❯ ctest -V
UpdateCTestConfiguration  from :S:/c/build/DartConfiguration.tcl
UpdateCTestConfiguration  from :S:/c/build/DartConfiguration.tcl
Test project S:/c/build
Constructing a list of tests
Done constructing a list of tests
Updating test list for fixtures
Added 0 tests to meet fixture requirements
Checking test dependency graph...
Checking test dependency graph end
test 1
    Start 1: az_core_test

1: Test command: S:\c\build\sdk\tests\core\Debug\az_core_test.exe
1: Environment variables:
1:  PATH=;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\\Extensions\Microsoft\IntelliCode\CLI;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.26.28801\bin\HostX86\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\VCPackages;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TestWindow;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\bin\Roslyn;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Team Tools\Performance Tools;C:\Program Files (x86)\Microsoft Visual Studio\Shared\Common\VSPerfCollectionTools\vs2019\;C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\FSharp\;C:\Program Files (x86)\Windows Kits\10\bin\10.0.18362.0\x86;C:\Program Files (x86)\Windows Kits\10\bin\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\\MSBuild\Current\Bin;C:\Windows\Microsoft.NET\Framework\v4.0.30319;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\dotnet\;C:\Program Files\Git\cmd;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Users\crist\AppData\Local\Microsoft\WindowsApps;C:\Users\crist\AppData\Local\Programs\Microsoft VS Code\bin;S:\Tools;c:\Program Files\Sublime Text 3;c:\Program Files\CMake\bin;C:\Program Files (x86)\Nmap;C:\Users\crist\OneDrive\Documents\WindowsPowerShell\Modules\Pscx\3.3.2\Apps;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\Ninja;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\Linux\bin\ConnectionManagerExe
1: Test timeout computed to be: 10000000
1: [==========] Running 1 test(s).
1: [ RUN      ] az_context_test
1: [       OK ] az_context_test
1: [==========] 1 test(s) run.
1: [  PASSED  ] 1 test(s).
1: [==========] Running 1 test(s).
1: [ RUN      ] test_credential_client_secret
1: [  ERROR   ] --- az_span_is_content_equal(expected_responses[i], response._internal.http_response)
1: [   LINE   ] --- S:\c\sdk\tests\core\test_az_credential_client_secret.c:93: error: Failure!
1: [  FAILED  ] test_credential_client_secret
1: [==========] 1 test(s) run.
1: [  PASSED  ] 0 test(s).
1: [  FAILED  ] 1 test(s), listed below:
1: [  FAILED  ] test_credential_client_secret
1:
1:  1 FAILED TEST(S)
1: [==========] Running 13 test(s).
1: [ RUN      ] test_http_request_removing_left_white_spaces
1: [       OK ] test_http_request_removing_left_white_spaces
1: [ RUN      ] test_http_request_header_validation
1: [       OK ] test_http_request_header_validation
1: [ RUN      ] test_http_request_header_validation_above_127
1: [       OK ] test_http_request_header_validation_above_127
1: [ RUN      ] test_http_response_append_null_response
1: [       OK ] test_http_response_append_null_response
1: [ RUN      ] test_http_request
1: [       OK ] test_http_request
1: [ RUN      ] test_http_response
1: [       OK ] test_http_response
1: [ RUN      ] test_http_request_header_validation_range
1: [       OK ] test_http_request_header_validation_range
1: [ RUN      ] test_http_response_header_validation
1: [       OK ] test_http_response_header_validation
1: [ RUN      ] test_http_response_header_validation_fail
1: [       OK ] test_http_response_header_validation_fail
1: [ RUN      ] test_http_response_header_validation_space
1: [       OK ] test_http_response_header_validation_space
1: [ RUN      ] test_http_response_append_overflow
1: [       OK ] test_http_response_append_overflow
1: [ RUN      ] test_http_response_append
1: [       OK ] test_http_response_append
1: [ RUN      ] test_http_response_append_overflow_on_second_call
1: [       OK ] test_http_response_append_overflow_on_second_call
1: [==========] 13 test(s) run.
1: [  PASSED  ] 13 test(s).
1: [==========] Running 6 test(s).
1: [ RUN      ] test_json_parser_init
1: [       OK ] test_json_parser_init
1: [ RUN      ] test_json_builder
1: [       OK ] test_json_builder
1: [ RUN      ] test_json_parser
1: [       OK ] test_json_parser
1: [ RUN      ] test_json_parser_invalid
1: [       OK ] test_json_parser_invalid
1: [ RUN      ] test_json_skip_children
1: [       OK ] test_json_skip_children
1: [ RUN      ] test_json_value
1: [       OK ] test_json_value
1: [==========] 6 test(s) run.
1: [  PASSED  ] 6 test(s).
1: [==========] Running 1 test(s).
1: [ RUN      ] test_az_log
1: [       OK ] test_az_log
1: [==========] 1 test(s) run.
1: [  PASSED  ] 1 test(s).
1: [==========] Running 1 test(s).
1: [ RUN      ] az_pipeline_test
1: [       OK ] az_pipeline_test
1: [==========] 1 test(s) run.
1: [  PASSED  ] 1 test(s).
1: [==========] Running 5 test(s).
1: [ RUN      ] test_az_http_pipeline_policy_retry
1: [  ERROR   ] --- %s() has remaining non-returned values.
1: S:\c\sdk\tests\core\test_az_policy.c:243: note: remaining item was declared here
1:
1: [  FAILED  ] test_az_http_pipeline_policy_retry
1: [ RUN      ] test_az_http_pipeline_policy_retry_with_header
1: [  ERROR   ] --- %s() has remaining non-returned values.
1: S:\c\sdk\tests\core\test_az_policy.c:283: note: remaining item was declared here
1:
1: [  FAILED  ] test_az_http_pipeline_policy_retry_with_header
1: [ RUN      ] test_az_http_pipeline_policy_retry_with_header_2
1: [  ERROR   ] --- %s() has remaining non-returned values.
1: S:\c\sdk\tests\core\test_az_policy.c:324: note: remaining item was declared here
1:
1: [  FAILED  ] test_az_http_pipeline_policy_retry_with_header_2
1: [ RUN      ] test_az_http_pipeline_policy_apiversion
1: [       OK ] test_az_http_pipeline_policy_apiversion
1: [ RUN      ] test_az_http_pipeline_policy_telemetry
1: [       OK ] test_az_http_pipeline_policy_telemetry
1: [==========] 5 test(s) run.
1: [  PASSED  ] 2 test(s).
1: [  FAILED  ] 3 test(s), listed below:
1: [  FAILED  ] test_az_http_pipeline_policy_retry
1: [  FAILED  ] test_az_http_pipeline_policy_retry_with_header
1: [  FAILED  ] test_az_http_pipeline_policy_retry_with_header_2
1:
1:  3 FAILED TEST(S)
1: [==========] Running 63 test(s).
1: [ RUN      ] az_span_slice_to_end_test
1: [       OK ] az_span_slice_to_end_test
1: [ RUN      ] test_az_span_getters
1: [       OK ] test_az_span_getters
1: [ RUN      ] az_single_char_ascii_lower_test
1: [       OK ] az_single_char_ascii_lower_test
1: [ RUN      ] az_span_to_lower_test
1: [       OK ] az_span_to_lower_test
1: [ RUN      ] az_span_to_str_test
1: [       OK ] az_span_to_str_test
1: [ RUN      ] test_az_span_is_content_equal
1: [       OK ] test_az_span_is_content_equal
1: [ RUN      ] az_span_find_beginning_success
1: [       OK ] az_span_find_beginning_success
1: [ RUN      ] az_span_find_middle_success
1: [       OK ] az_span_find_middle_success
1: [ RUN      ] az_span_find_end_success
1: [       OK ] az_span_find_end_success
1: [ RUN      ] az_span_find_source_target_identical_success
1: [       OK ] az_span_find_source_target_identical_success
1: [ RUN      ] az_span_find_not_found_fail
1: [       OK ] az_span_find_not_found_fail
1: [ RUN      ] az_span_find_error_cases_fail
1: [       OK ] az_span_find_error_cases_fail
1: [ RUN      ] az_span_find_target_longer_than_source_fails
1: [       OK ] az_span_find_target_longer_than_source_fails
1: [ RUN      ] az_span_find_target_overlap_continuation_of_source_fails
1: [       OK ] az_span_find_target_overlap_continuation_of_source_fails
1: [ RUN      ] az_span_find_target_more_chars_than_prefix_of_source_fails
1: [       OK ] az_span_find_target_more_chars_than_prefix_of_source_fails
1: [ RUN      ] az_span_find_overlapping_target_success
1: [       OK ] az_span_find_overlapping_target_success
1: [ RUN      ] az_span_find_embedded_NULLs_success
1: [       OK ] az_span_find_embedded_NULLs_success
1: [ RUN      ] az_span_find_capacity_checks_success
1: [       OK ] az_span_find_capacity_checks_success
1: [ RUN      ] az_span_find_overlapping_checks_success
1: [       OK ] az_span_find_overlapping_checks_success
1: [ RUN      ] test_az_span_replace
1: [       OK ] test_az_span_replace
1: [ RUN      ] az_span_atox_return_errors
1: [       OK ] az_span_atox_return_errors
1: [ RUN      ] az_span_atou32_test
1: [       OK ] az_span_atou32_test
1: [ RUN      ] az_span_atoi32_test
1: [       OK ] az_span_atoi32_test
1: [ RUN      ] az_span_atou64_test
1: [       OK ] az_span_atou64_test
1: [ RUN      ] az_span_atoi64_test
1: [       OK ] az_span_atoi64_test
1: [ RUN      ] az_span_atod_test
1: [       OK ] az_span_atod_test
1: [ RUN      ] az_span_ato_number_whitespace_or_invalid_not_allowed
1: [       OK ] az_span_ato_number_whitespace_or_invalid_not_allowed
1: [ RUN      ] az_span_ato_number_no_out_of_bounds_reads
1: [       OK ] az_span_ato_number_no_out_of_bounds_reads
1: [ RUN      ] az_span_i64toa_negative_number_test
1: [       OK ] az_span_i64toa_negative_number_test
1: [ RUN      ] az_span_i64toa_test
1: [       OK ] az_span_i64toa_test
1: [ RUN      ] az_span_test_macro_only_allows_byte_buffers
1: [       OK ] az_span_test_macro_only_allows_byte_buffers
1: [ RUN      ] az_span_from_str_succeeds
1: [       OK ] az_span_from_str_succeeds
1: [ RUN      ] az_span_copy_uint8_succeeds
1: [       OK ] az_span_copy_uint8_succeeds
1: [ RUN      ] az_span_i32toa_succeeds
1: [       OK ] az_span_i32toa_succeeds
1: [ RUN      ] az_span_i32toa_negative_succeeds
1: [       OK ] az_span_i32toa_negative_succeeds
1: [ RUN      ] az_span_i32toa_max_int_succeeds
1: [       OK ] az_span_i32toa_max_int_succeeds
1: [ RUN      ] az_span_i32toa_zero_succeeds
1: [       OK ] az_span_i32toa_zero_succeeds
1: [ RUN      ] az_span_i32toa_overflow_fails
1: [       OK ] az_span_i32toa_overflow_fails
1: [ RUN      ] az_span_u32toa_succeeds
1: [       OK ] az_span_u32toa_succeeds
1: [ RUN      ] az_span_u32toa_zero_succeeds
1: [       OK ] az_span_u32toa_zero_succeeds
1: [ RUN      ] az_span_u32toa_max_uint_succeeds
1: [       OK ] az_span_u32toa_max_uint_succeeds
1: [ RUN      ] az_span_u32toa_overflow_fails
1: [       OK ] az_span_u32toa_overflow_fails
1: [ RUN      ] az_span_dtoa_succeeds
1: [       OK ] az_span_dtoa_succeeds
1: [ RUN      ] az_span_dtoa_overflow_fails
1: [       OK ] az_span_dtoa_overflow_fails
1: [ RUN      ] az_span_dtoa_too_large
1: [       OK ] az_span_dtoa_too_large
1: [ RUN      ] az_span_copy_empty
1: [       OK ] az_span_copy_empty
1: [ RUN      ] test_az_span_is_valid
1: [       OK ] test_az_span_is_valid
1: [ RUN      ] test_az_span_overlap
1: [       OK ] test_az_span_overlap
1: [ RUN      ] az_span_trim
1: [       OK ] az_span_trim
1: [ RUN      ] az_span_trim_left
1: [       OK ] az_span_trim_left
1: [ RUN      ] az_span_trim_right
1: [       OK ] az_span_trim_right
1: [ RUN      ] az_span_trim_all_white
1: [       OK ] az_span_trim_all_white
1: [ RUN      ] az_span_trim_none
1: [       OK ] az_span_trim_none
1: [ RUN      ] az_span_trim_spaced
1: [       OK ] az_span_trim_spaced
1: [ RUN      ] az_span_trim_zero
1: [       OK ] az_span_trim_zero
1: [ RUN      ] az_span_trim_null
1: [       OK ] az_span_trim_null
1: [ RUN      ] test_az_span_token_success
1: [       OK ] test_az_span_token_success
1: [ RUN      ] az_span_trim_start
1: [       OK ] az_span_trim_start
1: [ RUN      ] az_span_trim_end
1: [       OK ] az_span_trim_end
1: [ RUN      ] az_span_trim_unicode
1: [       OK ] az_span_trim_unicode
1: [ RUN      ] az_span_trim_two_calls
1: [       OK ] az_span_trim_two_calls
1: [ RUN      ] az_span_trim_two_calls_inverse
1: [       OK ] az_span_trim_two_calls_inverse
1: [ RUN      ] az_span_trim_repeat_calls
1: [       OK ] az_span_trim_repeat_calls
1: [==========] 63 test(s) run.
1: [  PASSED  ] 63 test(s).
1: [==========] Running 4 test(s).
1: [ RUN      ] test_url_encode_basic
1: [       OK ] test_url_encode_basic
1: [ RUN      ] test_url_encode_preconditions
1: [       OK ] test_url_encode_preconditions
1: [ RUN      ] test_url_encode_usage
1: [       OK ] test_url_encode_usage
1: [ RUN      ] test_url_encode_full
1: [       OK ] test_url_encode_full
1: [==========] 4 test(s) run.
1: [  PASSED  ] 4 test(s).
1/5 Test #1: az_core_test .....................***Failed    0.10 sec
test 2
    Start 2: az_iot_common_test

2: Test command: S:\c\build\sdk\tests\iot\common\Debug\az_iot_common_test.exe
2: Environment variables:
2:  PATH=;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\\Extensions\Microsoft\IntelliCode\CLI;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.26.28801\bin\HostX86\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\VCPackages;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TestWindow;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\bin\Roslyn;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Team Tools\Performance Tools;C:\Program Files (x86)\Microsoft Visual Studio\Shared\Common\VSPerfCollectionTools\vs2019\;C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\FSharp\;C:\Program Files (x86)\Windows Kits\10\bin\10.0.18362.0\x86;C:\Program Files (x86)\Windows Kits\10\bin\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\\MSBuild\Current\Bin;C:\Windows\Microsoft.NET\Framework\v4.0.30319;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\dotnet\;C:\Program Files\Git\cmd;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Users\crist\AppData\Local\Microsoft\WindowsApps;C:\Users\crist\AppData\Local\Programs\Microsoft VS Code\bin;S:\Tools;c:\Program Files\Sublime Text 3;c:\Program Files\CMake\bin;C:\Program Files (x86)\Nmap;C:\Users\crist\OneDrive\Documents\WindowsPowerShell\Modules\Pscx\3.3.2\Apps;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\Ninja;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\Linux\bin\ConnectionManagerExe
2: Test timeout computed to be: 10000000
2: [==========] Running 8 test(s).
2: [ RUN      ] test_az_iot_u32toa_size_success
2: [       OK ] test_az_iot_u32toa_size_success
2: [ RUN      ] test_az_iot_is_success_status_translate_success
2: [       OK ] test_az_iot_is_success_status_translate_success
2: [ RUN      ] test_az_iot_is_retriable_status_translate_success
2: [       OK ] test_az_iot_is_retriable_status_translate_success
2: [ RUN      ] test_az_iot_retry_calc_delay_common_timings_success
2: [       OK ] test_az_iot_retry_calc_delay_common_timings_success
2: [ RUN      ] test_az_iot_retry_calc_delay_overflow_time_success
2: [       OK ] test_az_iot_retry_calc_delay_overflow_time_success
2: [ RUN      ] test_az_iot_provisioning_client_logging_succeed
2: [       OK ] test_az_iot_provisioning_client_logging_succeed
2: [ RUN      ] test_az_span_copy_url_encode_succeed
2: [       OK ] test_az_span_copy_url_encode_succeed
2: [ RUN      ] test_az_span_copy_url_encode_insufficient_size_fail
2: [       OK ] test_az_span_copy_url_encode_insufficient_size_fail
2: [==========] 8 test(s) run.
2: [  PASSED  ] 8 test(s).
2/5 Test #2: az_iot_common_test ...............   Passed    0.02 sec
test 3
    Start 3: az_iot_hub_test

3: Test command: S:\c\build\sdk\tests\iot\hub\Debug\az_iot_hub_test.exe
3: Environment variables:
3:  PATH=;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\\Extensions\Microsoft\IntelliCode\CLI;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.26.28801\bin\HostX86\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\VCPackages;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TestWindow;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\bin\Roslyn;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Team Tools\Performance Tools;C:\Program Files (x86)\Microsoft Visual Studio\Shared\Common\VSPerfCollectionTools\vs2019\;C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\FSharp\;C:\Program Files (x86)\Windows Kits\10\bin\10.0.18362.0\x86;C:\Program Files (x86)\Windows Kits\10\bin\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\\MSBuild\Current\Bin;C:\Windows\Microsoft.NET\Framework\v4.0.30319;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\dotnet\;C:\Program Files\Git\cmd;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Users\crist\AppData\Local\Microsoft\WindowsApps;C:\Users\crist\AppData\Local\Programs\Microsoft VS Code\bin;S:\Tools;c:\Program Files\Sublime Text 3;c:\Program Files\CMake\bin;C:\Program Files (x86)\Nmap;C:\Users\crist\OneDrive\Documents\WindowsPowerShell\Modules\Pscx\3.3.2\Apps;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\Ninja;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\Linux\bin\ConnectionManagerExe
3: Test timeout computed to be: 10000000
3: [==========] Running 9 test(s).
3: [ RUN      ] test_az_iot_hub_client_c2d_parse_received_topic_NULL_client_fail
3: [       OK ] test_az_iot_hub_client_c2d_parse_received_topic_NULL_client_fail
3: [ RUN      ] test_az_iot_hub_client_c2d_parse_received_topic_AZ_SPAN_NULL_received_topic_fail
3: [       OK ] test_az_iot_hub_client_c2d_parse_received_topic_AZ_SPAN_NULL_received_topic_fail
3: [ RUN      ] test_az_iot_hub_client_c2d_parse_received_topic_NULL_out_request_fail
3: [       OK ] test_az_iot_hub_client_c2d_parse_received_topic_NULL_out_request_fail
3: [ RUN      ] test_az_iot_hub_client_c2d_parse_received_topic_url_decoded_succeed
3: [       OK ] test_az_iot_hub_client_c2d_parse_received_topic_url_decoded_succeed
3: [ RUN      ] test_az_iot_hub_client_c2d_parse_received_topic_url_encoded_succeed
3: [       OK ] test_az_iot_hub_client_c2d_parse_received_topic_url_encoded_succeed
3: [ RUN      ] test_az_iot_hub_client_c2d_parse_received_topic_no_props_succeed
3: [       OK ] test_az_iot_hub_client_c2d_parse_received_topic_no_props_succeed
3: [ RUN      ] test_az_iot_hub_client_c2d_parse_received_topic_reject
3: [       OK ] test_az_iot_hub_client_c2d_parse_received_topic_reject
3: [ RUN      ] test_az_iot_hub_client_c2d_parse_received_topic_malformed_reject
3: [       OK ] test_az_iot_hub_client_c2d_parse_received_topic_malformed_reject
3: [ RUN      ] test_az_iot_hub_client_c2d_logging_succeed
3: [       OK ] test_az_iot_hub_client_c2d_logging_succeed
3: [==========] 9 test(s) run.
3: [  PASSED  ] 9 test(s).
3: [==========] Running 59 test(s).
3: [ RUN      ] test_az_iot_hub_client_init_NULL_client_fails
3: [       OK ] test_az_iot_hub_client_init_NULL_client_fails
3: [ RUN      ] test_az_iot_hub_client_init_NULL_device_id_fails
3: [       OK ] test_az_iot_hub_client_init_NULL_device_id_fails
3: [ RUN      ] test_az_iot_hub_client_init_NULL_hub_hostname_id_fails
3: [       OK ] test_az_iot_hub_client_init_NULL_hub_hostname_id_fails
3: [ RUN      ] test_az_iot_hub_client_get_user_name_NULL_client_fails
3: [       OK ] test_az_iot_hub_client_get_user_name_NULL_client_fails
3: [ RUN      ] test_az_iot_hub_client_get_user_name_NULL_input_span_fails
3: [       OK ] test_az_iot_hub_client_get_user_name_NULL_input_span_fails
3: [ RUN      ] test_az_iot_hub_client_get_user_name_NULL_output_span_fails
3: [       OK ] test_az_iot_hub_client_get_user_name_NULL_output_span_fails
3: [ RUN      ] test_az_iot_hub_client_get_user_name_with_model_id_NULL_client_fails
3: [       OK ] test_az_iot_hub_client_get_user_name_with_model_id_NULL_client_fails
3: [ RUN      ] test_az_iot_hub_client_get_user_name_with_model_id_NULL_model_id_span_fails
3: [       OK ] test_az_iot_hub_client_get_user_name_with_model_id_NULL_model_id_span_fails
3: [ RUN      ] test_az_iot_hub_client_get_user_name_with_model_id_NULL_input_span_fails
3: [       OK ] test_az_iot_hub_client_get_user_name_with_model_id_NULL_input_span_fails
3: [ RUN      ] test_az_iot_hub_client_get_user_name_with_model_id_NULL_output_span_fails
3: [       OK ] test_az_iot_hub_client_get_user_name_with_model_id_NULL_output_span_fails
3: [ RUN      ] test_az_iot_hub_client_get_client_id_NULL_client_fails
3: [       OK ] test_az_iot_hub_client_get_client_id_NULL_client_fails
3: [ RUN      ] test_az_iot_hub_client_get_client_id_NULL_input_span_fails
3: [       OK ] test_az_iot_hub_client_get_client_id_NULL_input_span_fails
3: [ RUN      ] test_az_iot_hub_client_get_client_id_NULL_output_span_fails
3: [       OK ] test_az_iot_hub_client_get_client_id_NULL_output_span_fails
3: [ RUN      ] test_az_iot_hub_client_properties_init_NULL_props_fails
3: [       OK ] test_az_iot_hub_client_properties_init_NULL_props_fails
3: [ RUN      ] test_az_iot_hub_client_properties_append_get_NULL_props_fails
3: [       OK ] test_az_iot_hub_client_properties_append_get_NULL_props_fails
3: [ RUN      ] test_az_iot_hub_client_properties_append_NULL_name_span_fails
3: [       OK ] test_az_iot_hub_client_properties_append_NULL_name_span_fails
3: [ RUN      ] test_az_iot_hub_client_properties_append_NULL_value_span_fails
3: [       OK ] test_az_iot_hub_client_properties_append_NULL_value_span_fails
3: [ RUN      ] test_az_iot_hub_client_properties_find_NULL_props_fail
3: [       OK ] test_az_iot_hub_client_properties_find_NULL_props_fail
3: [ RUN      ] test_az_iot_hub_client_properties_find_NULL_name_fail
3: [       OK ] test_az_iot_hub_client_properties_find_NULL_name_fail
3: [ RUN      ] test_az_iot_hub_client_properties_find_NULL_value_fail
3: [       OK ] test_az_iot_hub_client_properties_find_NULL_value_fail
3: [ RUN      ] test_az_iot_hub_client_properties_next_NULL_props_fail
3: [       OK ] test_az_iot_hub_client_properties_next_NULL_props_fail
3: [ RUN      ] test_az_iot_hub_client_properties_next_NULL_out_fail
3: [       OK ] test_az_iot_hub_client_properties_next_NULL_out_fail
3: [ RUN      ] test_az_iot_hub_client_get_default_options_succeed
3: [       OK ] test_az_iot_hub_client_get_default_options_succeed
3: [ RUN      ] test_az_iot_hub_client_init_succeed
3: [       OK ] test_az_iot_hub_client_init_succeed
3: [ RUN      ] test_az_iot_hub_client_init_custom_options_succeed
3: [       OK ] test_az_iot_hub_client_init_custom_options_succeed
3: [ RUN      ] test_az_iot_hub_client_get_user_name_succeed
3: [       OK ] test_az_iot_hub_client_get_user_name_succeed
3: [ RUN      ] test_az_iot_hub_client_get_user_name_small_buffer_fail
3: [       OK ] test_az_iot_hub_client_get_user_name_small_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_get_user_name_user_options_succeed
3: [       OK ] test_az_iot_hub_client_get_user_name_user_options_succeed
3: [ RUN      ] test_az_iot_hub_client_get_user_name_user_options_small_buffer_fail
3: [       OK ] test_az_iot_hub_client_get_user_name_user_options_small_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_get_user_name_with_model_id_succeed
3: [       OK ] test_az_iot_hub_client_get_user_name_with_model_id_succeed
3: [ RUN      ] test_az_iot_hub_client_get_user_name_with_model_id_small_buffer_fail
3: [       OK ] test_az_iot_hub_client_get_user_name_with_model_id_small_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_get_user_name_with_model_id_small_buffer_first_if_case_fail
3: [       OK ] test_az_iot_hub_client_get_user_name_with_model_id_small_buffer_first_if_case_fail
3: [ RUN      ] test_az_iot_hub_client_get_user_name_with_model_id_user_options_succeed
3: [       OK ] test_az_iot_hub_client_get_user_name_with_model_id_user_options_succeed
3: [ RUN      ] test_az_iot_hub_client_get_user_name_with_model_id_user_options_small_buffer_fail
3: [       OK ] test_az_iot_hub_client_get_user_name_with_model_id_user_options_small_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_get_client_id_succeed
3: [       OK ] test_az_iot_hub_client_get_client_id_succeed
3: [ RUN      ] test_az_iot_hub_client_get_client_id_small_buffer_fail
3: [       OK ] test_az_iot_hub_client_get_client_id_small_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_get_client_id_module_succeed
3: [       OK ] test_az_iot_hub_client_get_client_id_module_succeed
3: [ RUN      ] test_az_iot_hub_client_get_client_id_module_small_buffer_fail
3: [       OK ] test_az_iot_hub_client_get_client_id_module_small_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_properties_init_succeed
3: [       OK ] test_az_iot_hub_client_properties_init_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_init_user_set_params_succeed
3: [       OK ] test_az_iot_hub_client_properties_init_user_set_params_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_append_succeed
3: [       OK ] test_az_iot_hub_client_properties_append_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_append_empty_buffer_fail
3: [       OK ] test_az_iot_hub_client_properties_append_empty_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_properties_append_small_buffer_fail
3: [       OK ] test_az_iot_hub_client_properties_append_small_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_properties_append_twice_succeed
3: [       OK ] test_az_iot_hub_client_properties_append_twice_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_append_twice_small_buffer_fail
3: [       OK ] test_az_iot_hub_client_properties_append_twice_small_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_properties_find_succeed
3: [       OK ] test_az_iot_hub_client_properties_find_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_find_middle_succeed
3: [       OK ] test_az_iot_hub_client_properties_find_middle_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_find_end_succeed
3: [       OK ] test_az_iot_hub_client_properties_find_end_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_find_substring_succeed
3: [       OK ] test_az_iot_hub_client_properties_find_substring_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_find_name_value_same_succeed
3: [       OK ] test_az_iot_hub_client_properties_find_name_value_same_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_find_empty_buffer_fail
3: [       OK ] test_az_iot_hub_client_properties_find_empty_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_properties_find_fail
3: [       OK ] test_az_iot_hub_client_properties_find_fail
3: [ RUN      ] test_az_iot_hub_client_properties_find_substring_fail
3: [       OK ] test_az_iot_hub_client_properties_find_substring_fail
3: [ RUN      ] test_az_iot_hub_client_properties_find_substring_suffix_fail
3: [       OK ] test_az_iot_hub_client_properties_find_substring_suffix_fail
3: [ RUN      ] test_az_iot_hub_client_properties_find_value_match_fail
3: [       OK ] test_az_iot_hub_client_properties_find_value_match_fail
3: [ RUN      ] test_az_iot_hub_client_properties_find_value_match_end_fail
3: [       OK ] test_az_iot_hub_client_properties_find_value_match_end_fail
3: [ RUN      ] test_az_iot_hub_client_properties_next_succeed
3: [       OK ] test_az_iot_hub_client_properties_next_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_next_twice_succeed
3: [       OK ] test_az_iot_hub_client_properties_next_twice_succeed
3: [ RUN      ] test_az_iot_hub_client_properties_next_empty_succeed
3: [       OK ] test_az_iot_hub_client_properties_next_empty_succeed
3: [==========] 59 test(s) run.
3: [  PASSED  ] 59 test(s).
3: [==========] Running 19 test(s).
3: [ RUN      ] az_iot_hub_client_sas_get_signature_NULL_signature_fails
3: [       OK ] az_iot_hub_client_sas_get_signature_NULL_signature_fails
3: [ RUN      ] az_iot_hub_client_sas_get_signature_NULL_signature_span_fails
3: [       OK ] az_iot_hub_client_sas_get_signature_NULL_signature_span_fails
3: [ RUN      ] az_iot_hub_client_sas_get_signature_NULL_client_fails
3: [       OK ] az_iot_hub_client_sas_get_signature_NULL_client_fails
3: [ RUN      ] az_iot_hub_client_sas_get_password_EMPTY_signature_fails
3: [       OK ] az_iot_hub_client_sas_get_password_EMPTY_signature_fails
3: [ RUN      ] az_iot_hub_client_sas_get_password_NULL_password_span_fails
3: [       OK ] az_iot_hub_client_sas_get_password_NULL_password_span_fails
3: [ RUN      ] az_iot_hub_client_sas_get_password_empty_password_buffer_span_fails
3: [       OK ] az_iot_hub_client_sas_get_password_empty_password_buffer_span_fails
3: [ RUN      ] az_iot_hub_client_sas_get_signature_device_succeeds
3: [       OK ] az_iot_hub_client_sas_get_signature_device_succeeds
3: [ RUN      ] az_iot_hub_client_sas_get_password_device_no_out_length_succeeds
3: [       OK ] az_iot_hub_client_sas_get_password_device_no_out_length_succeeds
3: [ RUN      ] az_iot_hub_client_sas_get_signature_module_succeeds
3: [       OK ] az_iot_hub_client_sas_get_signature_module_succeeds
3: [ RUN      ] az_iot_hub_client_sas_get_password_module_no_length_succeeds
3: [       OK ] az_iot_hub_client_sas_get_password_module_no_length_succeeds
3: [ RUN      ] az_iot_hub_client_sas_get_password_device_succeeds
3: [       OK ] az_iot_hub_client_sas_get_password_device_succeeds
3: [ RUN      ] az_iot_hub_client_sas_get_password_module_succeeds
3: [       OK ] az_iot_hub_client_sas_get_password_module_succeeds
3: [ RUN      ] az_iot_hub_client_sas_get_password_device_with_keyname_succeeds
3: [       OK ] az_iot_hub_client_sas_get_password_device_with_keyname_succeeds
3: [ RUN      ] az_iot_hub_client_sas_get_password_module_with_keyname_succeeds
3: [       OK ] az_iot_hub_client_sas_get_password_module_with_keyname_succeeds
3: [ RUN      ] az_iot_hub_client_sas_get_password_device_overflow_fails
3: [       OK ] az_iot_hub_client_sas_get_password_device_overflow_fails
3: [ RUN      ] az_iot_hub_client_sas_get_password_module_overflow_fails
3: [       OK ] az_iot_hub_client_sas_get_password_module_overflow_fails
3: [ RUN      ] az_iot_hub_client_sas_get_signature_device_signature_overflow_fails
3: [       OK ] az_iot_hub_client_sas_get_signature_device_signature_overflow_fails
3: [ RUN      ] az_iot_hub_client_sas_get_signature_module_signature_overflow_fails
3: [       OK ] az_iot_hub_client_sas_get_signature_module_signature_overflow_fails
3: [ RUN      ] test_az_iot_hub_client_sas_logging_succeed
3: [       OK ] test_az_iot_hub_client_sas_logging_succeed
3: [==========] 19 test(s) run.
3: [  PASSED  ] 19 test(s).
3: [==========] Running 12 test(s).
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_NULL_client_fails
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_NULL_client_fails
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_NULL_mqtt_topic_fails
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_NULL_mqtt_topic_fails
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_NULL_out_mqtt_topic_fails
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_NULL_out_mqtt_topic_fails
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_no_options_no_props_succeed
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_no_options_no_props_succeed
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_no_props_succeed
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_no_props_succeed
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_with_props_succeed
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_with_props_succeed
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_with_props_unfilled_succeed
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_with_props_unfilled_succeed
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_with_props_small_buffer_fails
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_with_props_small_buffer_fails
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_no_options_with_props_succeed
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_no_options_with_props_succeed
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_no_options_with_props_small_buffer_fails
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_no_options_with_props_small_buffer_fails
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_module_id_with_props_succeed
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_module_id_with_props_succeed
3: [ RUN      ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_module_id_with_props_small_buffer_fails
3: [       OK ] test_az_iot_hub_client_telemetry_get_publish_topic_with_options_module_id_with_props_small_buffer_fails
3: [==========] 12 test(s) run.
3: [  PASSED  ] 12 test(s).
3: [==========] Running 21 test(s).
3: [ RUN      ] test_az_iot_hub_client_twin_document_get_publish_topic_NULL_client_fails
3: [       OK ] test_az_iot_hub_client_twin_document_get_publish_topic_NULL_client_fails
3: [ RUN      ] test_az_iot_hub_client_twin_document_get_publish_topic_NULL_request_id_fails
3: [       OK ] test_az_iot_hub_client_twin_document_get_publish_topic_NULL_request_id_fails
3: [ RUN      ] test_az_iot_hub_client_twin_document_get_publish_topic_NULL_span_fails
3: [       OK ] test_az_iot_hub_client_twin_document_get_publish_topic_NULL_span_fails
3: [ RUN      ] test_az_iot_hub_client_twin_document_get_publish_topic_NULL_out_span_fails
3: [       OK ] test_az_iot_hub_client_twin_document_get_publish_topic_NULL_out_span_fails
3: [ RUN      ] test_az_iot_hub_client_twin_patch_get_publish_topic_NULL_client_fails
3: [       OK ] test_az_iot_hub_client_twin_patch_get_publish_topic_NULL_client_fails
3: [ RUN      ] test_az_iot_hub_client_twin_patch_get_publish_topic_invalid_request_id_fails
3: [       OK ] test_az_iot_hub_client_twin_patch_get_publish_topic_invalid_request_id_fails
3: [ RUN      ] test_az_iot_hub_client_twin_patch_get_publish_topic_NULL_char_buf_fails
3: [       OK ] test_az_iot_hub_client_twin_patch_get_publish_topic_NULL_char_buf_fails
3: [ RUN      ] test_az_iot_hub_client_twin_patch_get_publish_topic_NULL_out_span_fails
3: [       OK ] test_az_iot_hub_client_twin_patch_get_publish_topic_NULL_out_span_fails
3: [ RUN      ] test_az_iot_hub_client_twin_parse_received_topic_NULL_client_fails
3: [       OK ] test_az_iot_hub_client_twin_parse_received_topic_NULL_client_fails
3: [ RUN      ] test_az_iot_hub_client_twin_parse_received_topic_NULL_rec_topic_fails
3: [       OK ] test_az_iot_hub_client_twin_parse_received_topic_NULL_rec_topic_fails
3: [ RUN      ] test_az_iot_hub_client_twin_parse_received_topic_NULL_response_fails
3: [       OK ] test_az_iot_hub_client_twin_parse_received_topic_NULL_response_fails
3: [ RUN      ] test_az_iot_hub_client_twin_document_get_publish_topic_succeed
3: [       OK ] test_az_iot_hub_client_twin_document_get_publish_topic_succeed
3: [ RUN      ] test_az_iot_hub_client_twin_document_get_publish_topic_small_buffer_fails
3: [       OK ] test_az_iot_hub_client_twin_document_get_publish_topic_small_buffer_fails
3: [ RUN      ] test_az_iot_hub_client_twin_patch_get_publish_topic_succeed
3: [       OK ] test_az_iot_hub_client_twin_patch_get_publish_topic_succeed
3: [ RUN      ] test_az_iot_hub_client_twin_patch_get_publish_topic_small_buffer_fails
3: [       OK ] test_az_iot_hub_client_twin_patch_get_publish_topic_small_buffer_fails
3: [ RUN      ] test_az_iot_hub_client_twin_parse_received_topic_desired_found_succeed
3: [       OK ] test_az_iot_hub_client_twin_parse_received_topic_desired_found_succeed
3: [ RUN      ] test_az_iot_hub_client_twin_parse_received_topic_get_response_found_succeed
3: [       OK ] test_az_iot_hub_client_twin_parse_received_topic_get_response_found_succeed
3: [ RUN      ] test_az_iot_hub_client_twin_parse_received_topic_reported_props_found_succeed
3: [       OK ] test_az_iot_hub_client_twin_parse_received_topic_reported_props_found_succeed
3: [ RUN      ] test_az_iot_hub_client_twin_parse_received_topic_not_found_fails
3: [       OK ] test_az_iot_hub_client_twin_parse_received_topic_not_found_fails
3: [ RUN      ] test_az_iot_hub_client_twin_parse_received_topic_not_found_prefix_fails
3: [       OK ] test_az_iot_hub_client_twin_parse_received_topic_not_found_prefix_fails
3: [ RUN      ] test_az_iot_hub_client_twin_logging_succeed
3: [       OK ] test_az_iot_hub_client_twin_logging_succeed
3: [==========] 21 test(s) run.
3: [  PASSED  ] 21 test(s).
3: [==========] Running 22 test(s).
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_NULL_out_topic_fail
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_NULL_out_topic_fail
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_NULL_client_fail
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_NULL_client_fail
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_zero_size_buffer_fail
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_zero_size_buffer_fail
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_EMPTY_request_id_fail
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_EMPTY_request_id_fail
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_AZ_SPAN_NULL_request_id_fail
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_AZ_SPAN_NULL_request_id_fail
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_NULL_client_fail
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_NULL_client_fail
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_EMPTY_received_topic_fail
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_EMPTY_received_topic_fail
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_AZ_SPAN_NULL_received_topic_fail
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_AZ_SPAN_NULL_received_topic_fail
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_NULL_out_request_fail
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_NULL_out_request_fail
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_succeed
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_succeed
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_user_status_succeed
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_user_status_succeed
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_user_status_small_buf_fail
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_user_status_small_buf_fail
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_INSUFFICIENT_BUFFER_for_prefix_fail
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_INSUFFICIENT_BUFFER_for_prefix_fail
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_INSUFFICIENT_BUFFER_for_status_fail
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_INSUFFICIENT_BUFFER_for_status_fail
3: [ RUN      ] test_az_iot_hub_client_methods_response_get_publish_topic_INSUFFICIENT_BUFFER_for_reqid_fail
3: [       OK ] test_az_iot_hub_client_methods_response_get_publish_topic_INSUFFICIENT_BUFFER_for_reqid_fail
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_succeed
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_succeed
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_c2d_topic_fail
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_c2d_topic_fail
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_get_twin_topic_fail
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_get_twin_topic_fail
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_twin_patch_topic_fail
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_twin_patch_topic_fail
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_topic_filter_fail
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_topic_filter_fail
3: [ RUN      ] test_az_iot_hub_client_methods_parse_received_topic_response_topic_fail
3: [       OK ] test_az_iot_hub_client_methods_parse_received_topic_response_topic_fail
3: [ RUN      ] test_az_iot_hub_client_methods_logging_succeed
3: [       OK ] test_az_iot_hub_client_methods_logging_succeed
3: [==========] 22 test(s) run.
3: [  PASSED  ] 22 test(s).
3/5 Test #3: az_iot_hub_test ..................   Passed    0.11 sec
test 4
    Start 4: az_iot_provisioning_test

4: Test command: S:\c\build\sdk\tests\iot\provisioning\Debug\az_iot_provisioning_test.exe
4: Environment variables:
4:  PATH=;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\\Extensions\Microsoft\IntelliCode\CLI;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.26.28801\bin\HostX86\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\VCPackages;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TestWindow;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\bin\Roslyn;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Team Tools\Performance Tools;C:\Program Files (x86)\Microsoft Visual Studio\Shared\Common\VSPerfCollectionTools\vs2019\;C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\FSharp\;C:\Program Files (x86)\Windows Kits\10\bin\10.0.18362.0\x86;C:\Program Files (x86)\Windows Kits\10\bin\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\\MSBuild\Current\Bin;C:\Windows\Microsoft.NET\Framework\v4.0.30319;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\dotnet\;C:\Program Files\Git\cmd;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Users\crist\AppData\Local\Microsoft\WindowsApps;C:\Users\crist\AppData\Local\Programs\Microsoft VS Code\bin;S:\Tools;c:\Program Files\Sublime Text 3;c:\Program Files\CMake\bin;C:\Program Files (x86)\Nmap;C:\Users\crist\OneDrive\Documents\WindowsPowerShell\Modules\Pscx\3.3.2\Apps;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\Ninja;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\Linux\bin\ConnectionManagerExe
4: Test timeout computed to be: 10000000
4: [==========] Running 8 test(s).
4: [ RUN      ] test_az_iot_provisioning_client_options_default_succeed
4: [       OK ] test_az_iot_provisioning_client_options_default_succeed
4: [ RUN      ] test_az_iot_provisioning_client_default_options_get_connect_info_succeed
4: [       OK ] test_az_iot_provisioning_client_default_options_get_connect_info_succeed
4: [ RUN      ] test_az_iot_provisioning_client_custom_options_get_username_succeed
4: [       OK ] test_az_iot_provisioning_client_custom_options_get_username_succeed
4: [ RUN      ] test_az_iot_provisioning_client_get_connect_info_insufficient_space_fails
4: [       OK ] test_az_iot_provisioning_client_get_connect_info_insufficient_space_fails
4: [ RUN      ] test_az_iot_provisioning_client_get_register_publish_topic_succeed
4: [       OK ] test_az_iot_provisioning_client_get_register_publish_topic_succeed
4: [ RUN      ] test_az_iot_provisioning_client_get_register_publish_topic_insufficient_space_fails
4: [       OK ] test_az_iot_provisioning_client_get_register_publish_topic_insufficient_space_fails
4: [ RUN      ] test_az_iot_provisioning_client_get_operation_status_publish_topic_succeed
4: [       OK ] test_az_iot_provisioning_client_get_operation_status_publish_topic_succeed
4: [ RUN      ] test_az_iot_provisioning_client_get_operation_status_publish_topic_insufficient_space_fails
4: [       OK ] test_az_iot_provisioning_client_get_operation_status_publish_topic_insufficient_space_fails
4: [==========] 8 test(s) run.
4: [  PASSED  ] 8 test(s).
4: [==========] Running 12 test(s).
4: [ RUN      ] az_iot_provisioning_client_sas_get_signature_NULL_signature_fails
4: [       OK ] az_iot_provisioning_client_sas_get_signature_NULL_signature_fails
4: [ RUN      ] az_iot_provisioning_client_sas_get_signature_NULL_signature_span_fails
4: [       OK ] az_iot_provisioning_client_sas_get_signature_NULL_signature_span_fails
4: [ RUN      ] az_iot_provisioning_client_sas_get_signature_NULL_client_fails
4: [       OK ] az_iot_provisioning_client_sas_get_signature_NULL_client_fails
4: [ RUN      ] az_iot_provisioning_client_sas_get_password_EMPTY_signature_fails
4: [       OK ] az_iot_provisioning_client_sas_get_password_EMPTY_signature_fails
4: [ RUN      ] az_iot_provisioning_client_sas_get_password_NULL_password_span_fails
4: [       OK ] az_iot_provisioning_client_sas_get_password_NULL_password_span_fails
4: [ RUN      ] az_iot_provisioning_client_sas_get_password_empty_password_buffer_fails
4: [       OK ] az_iot_provisioning_client_sas_get_password_empty_password_buffer_fails
4: [ RUN      ] az_iot_provisioning_client_sas_get_signature_device_succeeds
4: [       OK ] az_iot_provisioning_client_sas_get_signature_device_succeeds
4: [ RUN      ] az_iot_provisioning_client_sas_get_password_device_succeeds
4: [       OK ] az_iot_provisioning_client_sas_get_password_device_succeeds
4: [ RUN      ] az_iot_provisioning_client_sas_get_password_device_with_keyname_succeeds
4: [       OK ] az_iot_provisioning_client_sas_get_password_device_with_keyname_succeeds
4: [ RUN      ] az_iot_provisioning_client_sas_get_password_device_overflow_fails
4: [       OK ] az_iot_provisioning_client_sas_get_password_device_overflow_fails
4: [ RUN      ] az_iot_provisioning_client_sas_get_signature_device_signature_overflow_fails
4: [       OK ] az_iot_provisioning_client_sas_get_signature_device_signature_overflow_fails
4: [ RUN      ] test_az_iot_provisioning_client_sas_logging_succeed
4: [       OK ] test_az_iot_provisioning_client_sas_logging_succeed
4: [==========] 12 test(s) run.
4: [  PASSED  ] 12 test(s).
4: [==========] Running 18 test(s).
4: [ RUN      ] test_az_iot_provisioning_client_parse_received_topic_and_payload_assigning_state_succeed
4: [       OK ] test_az_iot_provisioning_client_parse_received_topic_and_payload_assigning_state_succeed
4: [ RUN      ] test_az_iot_provisioning_client_parse_received_topic_and_payload_topic_not_matched_fails
4: [       OK ] test_az_iot_provisioning_client_parse_received_topic_and_payload_topic_not_matched_fails
4: [ RUN      ] test_az_iot_provisioning_client_parse_received_topic_and_payload_parse_assigning2_state_succeed
4: [       OK ] test_az_iot_provisioning_client_parse_received_topic_and_payload_parse_assigning2_state_succeed
4: [ RUN      ] test_az_iot_provisioning_client_parse_received_topic_and_payload_assigned_state_succeed
4: [       OK ] test_az_iot_provisioning_client_parse_received_topic_and_payload_assigned_state_succeed
4: [ RUN      ] test_az_iot_provisioning_client_parse_received_topic_and_payload_invalid_certificate_error_succeed
4: [       OK ] test_az_iot_provisioning_client_parse_received_topic_and_payload_invalid_certificate_error_succeed
4: [ RUN      ] test_az_iot_provisioning_client_parse_received_topic_payload_disabled_state_succeed
4: [       OK ] test_az_iot_provisioning_client_parse_received_topic_payload_disabled_state_succeed
4: [ RUN      ] test_az_iot_provisioning_client_parse_received_topic_and_payload_allocation_error_state_succeed
4: [       OK ] test_az_iot_provisioning_client_parse_received_topic_and_payload_allocation_error_state_succeed
4: [ RUN      ] test_az_iot_provisioning_client_received_topic_and_payload_parse_invalid_json_payload_fails
4: [       OK ] test_az_iot_provisioning_client_received_topic_and_payload_parse_invalid_json_payload_fails
4: [ RUN      ] test_az_iot_provisioning_client_received_topic_and_payload_parse_operationid_not_found_fails
4: [       OK ] test_az_iot_provisioning_client_received_topic_and_payload_parse_operationid_not_found_fails
4: [ RUN      ] test_az_iot_provisioning_client_received_topic_and_payload_parse_operation_status_not_found_fails
4: [       OK ] test_az_iot_provisioning_client_received_topic_and_payload_parse_operation_status_not_found_fails
4: [ RUN      ] test_az_iot_provisioning_client_received_topic_and_payload_parse_error_code_not_found_fails
4: [       OK ] test_az_iot_provisioning_client_received_topic_and_payload_parse_error_code_not_found_fails
4: [ RUN      ] test_az_iot_provisioning_client_received_topic_and_payload_parse_invalid_operation_status_fails
4: [       OK ] test_az_iot_provisioning_client_received_topic_and_payload_parse_invalid_operation_status_fails
4: [ RUN      ] test_az_iot_provisioning_client_received_topic_and_payload_parse_invalid_result_json_fails
4: [       OK ] test_az_iot_provisioning_client_received_topic_and_payload_parse_invalid_result_json_fails
4: [ RUN      ] test_az_iot_provisioning_client_received_topic_and_payload_parse_hub_not_found_fails
4: [       OK ] test_az_iot_provisioning_client_received_topic_and_payload_parse_hub_not_found_fails
4: [ RUN      ] test_az_iot_provisioning_client_received_topic_and_payload_parse_device_not_found_fails
4: [       OK ] test_az_iot_provisioning_client_received_topic_and_payload_parse_device_not_found_fails
4: [ RUN      ] test_az_iot_provisioning_client_parse_operation_status_translate_succeed
4: [       OK ] test_az_iot_provisioning_client_parse_operation_status_translate_succeed
4: [ RUN      ] test_az_iot_provisioning_client_operation_complete_translate_succeed
4: [       OK ] test_az_iot_provisioning_client_operation_complete_translate_succeed
4: [ RUN      ] test_az_iot_provisioning_client_logging_succeed
4: [       OK ] test_az_iot_provisioning_client_logging_succeed
4: [==========] 18 test(s) run.
4: [  PASSED  ] 18 test(s).
4/5 Test #4: az_iot_provisioning_test .........   Passed    0.04 sec
test 5
    Start 5: az_storage_blobs_test

5: Test command: S:\c\build\sdk\tests\storage\blobs\Debug\az_storage_blobs_test.exe
5: Environment variables:
5:  PATH=;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\\Extensions\Microsoft\IntelliCode\CLI;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.26.28801\bin\HostX86\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\VCPackages;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TestWindow;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\bin\Roslyn;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Team Tools\Performance Tools;C:\Program Files (x86)\Microsoft Visual Studio\Shared\Common\VSPerfCollectionTools\vs2019\;C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\FSharp\;C:\Program Files (x86)\Windows Kits\10\bin\10.0.18362.0\x86;C:\Program Files (x86)\Windows Kits\10\bin\x86;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\\MSBuild\Current\Bin;C:\Windows\Microsoft.NET\Framework\v4.0.30319;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\dotnet\;C:\Program Files\Git\cmd;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Users\crist\AppData\Local\Microsoft\WindowsApps;C:\Users\crist\AppData\Local\Programs\Microsoft VS Code\bin;S:\Tools;c:\Program Files\Sublime Text 3;c:\Program Files\CMake\bin;C:\Program Files (x86)\Nmap;C:\Users\crist\OneDrive\Documents\WindowsPowerShell\Modules\Pscx\3.3.2\Apps;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\Ninja;C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\VC\Linux\bin\ConnectionManagerExe
5: Test timeout computed to be: 10000000
5: [==========] Running 1 test(s).
5: [ RUN      ] test_storage_blobs_init
5: [       OK ] test_storage_blobs_init
5: [==========] 1 test(s) run.
5: [  PASSED  ] 1 test(s).
5/5 Test #5: az_storage_blobs_test ............   Passed    0.01 sec

80% tests passed, 1 tests failed out of 5

Total Test time (real) =   0.35 sec

The following tests FAILED:
          1 - az_core_test (Failed)
Errors while running CTest
CIPop commented 4 years ago

I can still repro on my machine on the latest master commit: a25ddc7e2ea821bf8b09c6ed2cfa59ce51e3cf81.

This is a bit concerning because the build machine isn't catching the issue. I'll look closer as well (this is a bit concerning as the build box appears to work just fine...)

vhvb1989 commented 4 years ago

I see, so, you should remove this option image when building on Windows. Since the -ld flag won't be recognized by the linker on MSVC. (it's gcc only)

Then, the other thing you might want when testing is to use the default PAL implementation, and not the Win32. The error can be reproduced whenever the build is generated with -DAZ_PLATFORM_IMPL=win32 on Windows because tests will use platform functions for sleep/clock that will lead to test timeout.

Make sure for testing on Windows, to do not set -DAZ_PLATFORM_IMPL. That will build core with az_noplatform where sleep and clock returns without actually doing nothing.

vhvb1989 commented 4 years ago

and not setting UNIT_TESTING_MOCKS will avoid this error: image

CIPop commented 4 years ago

@ahsonkhan @vhvb1989 /cc @gilbertw, @ericwol-msft this isn't failing in CI because it doesn't run this combination which means that only some tests are never executed in CI: (see archetype-sdk-client.yml cmake combinations: none of the options are "all enabled".

@vhvb1989 I think this was working for me before: why would a UT fail due to a linker option? UTs should not depend on linker options being available or not IMO.

vhvb1989 commented 4 years ago

@CIPop , the build combination with MOCK_ENABLED was created only for Linux (GCC) any other platform is not supported/tested for that.

@RickWinter was working to improve this by having a mocked implementation for PAL and HTTP Adapter.

The problem of running some tests with PAL functions is that some tests would take a lot of time (due to the sleep_sec() ). Then we would need to increase ctest timeout and add a couple of minutes to each PR checks. (not that I don't like it, but we are not really testing platfom APIs for sleeping).

For the HTTP adapter is an easy way to fake the network result without sending a request. We can't have real requests in CI to Azure because we need credentials. We have the nightly live tests for that.

RickWinter commented 4 years ago

@CIPop @antkmsft The CMAKE file can be smarter and detect when windows and MOCKS are turned on. CMake should error out in that case. I'm turning this into a bug and marking up for grabs. Please self-assign when/if you take it

CIPop commented 4 years ago

@RickWinter @JeffreyRichter @vhvb1989 Having a Linux hard dependency for UTs means Windows or Mac are not really development environments: they can be used to build and run the SDK only.

I think that is OK and the bug can be closed as long as we properly document this limitation. Changing all options that are OS-particular to something like LINUX_ONLY_ should be sufficient to avoid others spending the time, opening bugs, etc.

@vhvb1989 do you know of any other cmake options that are OS specific? We could change all of them then close the bug.

vhvb1989 commented 4 years ago

Having a Linux hard dependency for UTs means Windows or Mac... The dependency is only for testing http transport policy and retry policy. No other tests in SDK are impacted by this. Transport policy needs to re-wire the send function because there is no point on doing Network calls when we can mock them. Retry policy needs to re-wire the sleep_sec() PAL function. There is also no point on really sleeping on UT.

The fix mentioned by @RickWinter makes sense. CMake can detect if MOCK option is ON on MSVC and fail during Generate step with a description like "MOCKED is only supported on GCC".

We can actually use Windows or Mac, we just need to use GCC compiler there.. Instead of MSVC or others

vhvb1989 commented 4 years ago

do you know of any other cmake options that are OS specific?

I would call it "Compiler-specific" . UNIT_TESTING_MOCKS is the only one that is GCC supported only. (no matter what OS). If we use Linux with clang compiler we will also see this scenario.

CIPop commented 4 years ago

I would call it "Compiler-specific" . UNIT_TESTING_MOCKS is the only one that is GCC supported only. (no matter what OS). If we use Linux with clang compiler we will also see this scenario.

@vhvb1989 I agree: let's do the fix that @RickWinter is proposing. Another idea would be to enable gate tests on all OSs with all options using gcc (i.e. include Win, Mac) and document how a dev would need to configure his machine to get it to work on those systems.