aws-sdk-cpp: HttpClientTest.TestRandomURLMultiThreaded test failure on Ubuntu 18.04 LTS

Confirm by changing [ ] to [x] below:

Platform/OS/Hardware/Device What are you running the sdk on? Linux Ubuntu bionic 18.04 LTS

Describe the question I am using AWS_SDK_VERSION_STRING “1.8.62”. I was having problem in making http request while i am using sns client publish method. The crash occurs after random number of successful publish call but it occurs certainly. I was suggested that i should recompile c++ aws sdk. SDK got compiled successfully but i get error in tests. 2 tests are failed

/home/{localuser}/Desktop/github/aws-sdk-cpp/aws-cpp-sdk-core-tests/utils/crypto/SymmetricCiphersTest.cpp:696: Failure [build] Value of: *cipherDe [build] Actual: true [build] Expected: false

[build] [ FAILED ] HttpClientTest.TestRandomURLMultiThreaded (40081 ms) [build] [ RUN ] HttpClientTest.TestRandomURL [build] [ OK ] HttpClientTest.TestRandomURL (20020 ms) [build] [----------] 2 tests from HttpClientTest (60101 ms total)

suggest me possible fixes for these test failures. I have gone through the developers document and i have installed essential binaries. I have curl of version 7.72.0 19-08-2020 and openSSL 1.1.1h 22-09-2020, GCC 9.3.0

Logs/output If applicable, add logs or error output.

[build] [==========] 377 tests from 67 test cases ran. (67391 ms total) [build] [ PASSED ] 375 tests. [build] [ FAILED ] 2 tests, listed below: [build] [ FAILED ] HttpClientTest.TestRandomURLMultiThreaded [build] [ FAILED ] AES_GCM_TEST.AES_GCM_256_KAT_1 [build] [build] 2 FAILED TESTS [build] aws-cpp-sdk-core-tests/CMakeFiles/aws-cpp-sdk-core-tests.dir/build.make:814: recipe for target ‘aws-cpp-sdk-core-tests/aws-cpp-sdk-core-tests’ failed [build] CMakeFiles/Makefile2:822: recipe for target ‘aws-cpp-sdk-core-tests/CMakeFiles/aws-cpp-sdk-core-tests.dir/all’ failed [build] Makefile:148: recipe for target ‘all’ failed [build] make[2]: *** [aws-cpp-sdk-core-tests/aws-cpp-sdk-core-tests] Error 1 [build] make[2]: *** Deleting file ‘aws-cpp-sdk-core-tests/aws-cpp-sdk-core-tests’ [build] make[1]: *** [aws-cpp-sdk-core-tests/CMakeFiles/aws-cpp-sdk-core-tests.dir/all] Error 2 [build] make: *** [all] Error 2

To enable logging, set the following system properties:

REMEMBER TO SANITIZE YOUR PERSONAL INFO

options.loggingOptions.logLevel = Aws::Utils::Logging::LogLevel::Trace;
Aws::InitAPI(options)

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Reactions: 4
  • Comments: 27 (4 by maintainers)

Most upvoted comments

A workaround for me was to add -DAUTORUN_UNIT_TESTS=OFF

same issue on NixOS: gcc: 10.3.0 (compiled) cmake: 3.19.7 (compiled) aws-cpp-sdk: 1.8.121

Not behind firewall

for nixos users, to work around in an overlay: aws-sdk-cpp = super.aws-sdk-cpp.overrideAttrs(superAttrs: {
cmakeFlags = superAttrs.cmakeFlags or [] ++ [ “-DAUTORUN_UNIT_TESTS=OFF” ];
});

This has been pretty hard to reproduce, it seems like it is an error on the user side configuration but it’s hard to say from just the error messages displayed, can someone who is still seeing this error verify :

  • gcc and g++ version being used (make sure cmake is using the correct one in case you have multiple versions installed, remember it has to be 4.9 or higher).
  • Slow internet should not be a problem but a firewall blocking the connection would be, for reference this is not a unit test but a services integrations test, and yea we assume you’ll have internet connection for them. If you want to simply build then set -DENABLE_TESTING=OFF on your cmake command.