Skip to content

Commit 1aef2a8

Browse files
committed
# This is a combination of 21 commits.
# This is the 1st commit message: s3 code gen updates # This is the commit message #2: fixes # This is the commit message #3: updates # This is the commit message #4: updates # This is the commit message #5: compiling version # This is the commit message #6: updates # This is the commit message #7: test changes # This is the commit message #8: updates # This is the commit message #9: temp changes in s3client # This is the commit message #10: for debug # This is the commit message #11: Update API model # This is the commit message #12: corrects the dual-stack endpoint configuration for cognitoidp Added DeleteContactFlowVersion API and the CAMPAIGN flow type AWS IoT SiteWise now supports ingestion and querying of Null (all data types) and NaN (double type) values of bad or uncertain data quality. New partial error handling prevents data loss during ingestion. Enabled by default for new customers; existing customers can opt-in. Documentation-only update to address doc errors Documentation-only update: clarified the description of the shareDecaySeconds parameter of the FairsharePolicy data type, clarified the description of the priority parameter of the JobQueueDetail data type. Added `DigitGroupingStyle` in ThousandsSeparator to allow grouping by `LAKH`( Indian Grouping system ) currency. Support LAKH and `CRORE` currency types in Column Formatting. This release adds support for the topic attribute FifoThroughputScope for SNS FIFO topics. For details, see the documentation history in the Amazon Simple Notification Service Developer Guide. Increasing entryPoint in SparkSubmit to accept longer script paths. New limit is 4kb. # This is the commit message #13: upgrade smithy version (#3263) # This is the commit message #14: Refactor and simplify logic in sdksCommon cmake script to not rely on c2j model (#3251) # This is the commit message #15: Update API model # This is the commit message #16: Adds multi-turn input support for an Agent node in an Amazon Bedrock Flow Docs Update for timeout changes Rename WorkSpaces Web to WorkSpaces Secure Browser AWS Elemental MediaLive adds a new feature, ID3 segment tagging, in CMAF Ingest output groups. It allows customers to insert ID3 tags into every output segment, controlled by a newly added channel schedule action Id3SegmentTagging. # This is the commit message #17: Fix serialization for query xml # This is the commit message #18: Update API model # This is the commit message #19: Added "future" allocation type for future dated capacity reservation # This is the commit message #20: add stable order for smoke tests + restoring client codegen (#3265) # This is the commit message #21: add protocol test models (clients+tests) to the repo
1 parent d421218 commit 1aef2a8

File tree

1,264 files changed

+175956
-190948
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,264 files changed

+175956
-190948
lines changed

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.11.488
1+
1.11.491

cmake/sdks.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,6 @@ function(add_sdks)
214214
endif()
215215

216216
add_subdirectory("${SDK_DIR}")
217-
message(STATUS "exporting ${SDK_TARGET}")
218217
LIST(APPEND EXPORTS "${SDK_TARGET}")
219218
unset(SDK_TARGET)
220219
endforeach()

cmake/sdksCommon.cmake

Lines changed: 36 additions & 108 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,11 @@
11
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
22
# SPDX-License-Identifier: Apache-2.0.
3-
#
43

5-
# helper function that that gives primitive map functionality by treating a colon as the key-value separator, while the list semi-colon separates pairs
6-
# to use, pass the list-map in as a third parameter (see helper functions below)
7-
function(get_map_element KEY VALUE_VAR)
8-
foreach(ELEMENT_PAIR ${ARGN})
9-
STRING(REGEX REPLACE "([^:]+):.*" "\\1" KEY_RESULT ${ELEMENT_PAIR})
10-
if(${KEY_RESULT} STREQUAL ${KEY} )
11-
STRING(REGEX REPLACE "[^:]+:(.*)" "\\1" VALUE_RESULT ${ELEMENT_PAIR})
12-
set(${VALUE_VAR} "${VALUE_RESULT}" PARENT_SCOPE)
13-
return()
14-
endif()
15-
endforeach()
16-
set(${VALUE_VAR} "" PARENT_SCOPE)
17-
endfunction(get_map_element)
18-
19-
function(get_multimap_element KEY VALUE_VAR)
4+
# Return all values for a key from a flatmap
5+
# I.e. given a flatmap list of items such as "key1:val1,val2,val3;key2:val2;key1:valDoNotLoseMe" and "key1" as arguments
6+
# when called such as "get_flatmap_value(${TEST_NAME} TEMP_VAR ${TEST_DEPENDENCY_LIST})"
7+
# will return "val1,val2,val3,valDoNotLoseMe"
8+
function(get_flatmap_value KEY VALUE_VAR)
209
set(${VALUE_VAR} "" PARENT_SCOPE)
2110
set(RETURN_LIST "")
2211
foreach(ELEMENT_PAIR ${ARGN})
@@ -27,39 +16,30 @@ function(get_multimap_element KEY VALUE_VAR)
2716
endif()
2817
endforeach()
2918
set(${VALUE_VAR} "${RETURN_LIST}" PARENT_SCOPE)
30-
endfunction(get_multimap_element)
31-
32-
# a bunch of key-value retrieval functions for the list-maps we defined above
33-
function(get_c2j_date_for_service SERVICE_NAME C2J_DATE_VAR)
34-
get_map_element(${SERVICE_NAME} TEMP_VAR ${C2J_LIST})
35-
set(${C2J_DATE_VAR} "${TEMP_VAR}" PARENT_SCOPE)
36-
endfunction()
37-
38-
function(get_c2j_name_for_service SERVICE_NAME C2J_NAME_VAR)
39-
get_map_element(${SERVICE_NAME} TEMP_VAR ${C2J_SPECIAL_NAME_LIST})
40-
if(TEMP_VAR)
41-
set(${C2J_NAME_VAR} "${TEMP_VAR}" PARENT_SCOPE)
42-
else()
43-
set(${C2J_NAME_VAR} "${SERVICE_NAME}" PARENT_SCOPE)
44-
endif()
45-
endfunction()
19+
endfunction(get_flatmap_value)
4620

4721
function(get_test_projects_for_service SERVICE_NAME TEST_PROJECT_NAME_VAR)
48-
get_multimap_element(${SERVICE_NAME} TEMP_VAR ${SDK_TEST_PROJECT_LIST})
22+
get_flatmap_value(${SERVICE_NAME} TEMP_VAR ${SDK_TEST_PROJECT_LIST})
4923
set(${TEST_PROJECT_NAME_VAR} "${TEMP_VAR}" PARENT_SCOPE)
5024
endfunction()
5125

5226
function(get_dependencies_for_sdk PROJECT_NAME DEPENDENCY_LIST_VAR)
53-
get_map_element(${PROJECT_NAME} TEMP_VAR ${SDK_DEPENDENCY_LIST})
27+
get_flatmap_value(${PROJECT_NAME} TEMP_VAR ${SDK_DEPENDENCY_LIST})
28+
if (TEMP_VAR)
29+
string(REPLACE "," ";" TEMP_LIST_VAR ${TEMP_VAR})
30+
list(FIND TEMP_LIST_VAR "core" _index)
31+
if (${_index} GREATER -1) # old cmake search in a list syntax
32+
# core is already there
33+
set(${DEPENDENCY_LIST_VAR} "${TEMP_VAR}" PARENT_SCOPE)
34+
return()
35+
endif()
36+
endif()
5437
# "core" is the default dependency for every sdk.
55-
# Since we removed the hand-written C2J_LIST and instead auto generating it based on models,
56-
# and location of models may not exist or incorrect when SDK is installed and then source has been deleted by customers.
57-
# we end up getting an incomplete C2J_LIST when customers call find_package(AWSSDK). But C2J_LIST is only used in customers code for dependencies completing.
5838
set(${DEPENDENCY_LIST_VAR} "${TEMP_VAR},core" PARENT_SCOPE)
5939
endfunction()
6040

6141
function(get_dependencies_for_test TEST_NAME DEPENDENCY_LIST_VAR)
62-
get_map_element(${TEST_NAME} TEMP_VAR ${TEST_DEPENDENCY_LIST})
42+
get_flatmap_value(${TEST_NAME} TEMP_VAR ${TEST_DEPENDENCY_LIST})
6343
set(${DEPENDENCY_LIST_VAR} "${TEMP_VAR}" PARENT_SCOPE)
6444
endfunction()
6545

@@ -80,69 +60,21 @@ function(get_sdks_depending_on SDK_NAME DEPENDING_SDKS_VAR)
8060
set(${DEPENDING_SDKS_VAR} "${TEMP_SDK_LIST}" PARENT_SCOPE)
8161
endfunction()
8262

83-
# function that automatically picks up models from <sdkrootdir>/code-generation/api-descriptions/ directory and build
84-
# C2J_LIST needed for generation, services have multiple models will use the latest model (decided by model files' date)
85-
# services have the name format abc.def.ghi will be renamed to ghi-def-abc (dot will not be accepted as Windows directory name )
86-
# and put into C2J_SPECIAL_NAME_LIST, but rumtime.lex will be renamed to lex based on historical reason.
63+
# Function that reads <repo>/src/generated and builds a list of all available generated service clients for a build,
64+
# The resulting $SERVICE_CLIENT_LIST is as simple as "cognito-identity,s3,dynamodb,etc,..."
8765
function(build_sdk_list)
88-
file(GLOB ALL_MODEL_FILES "${CMAKE_CURRENT_SOURCE_DIR}/tools/code-generation/api-descriptions/*-[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9].normal.json")
89-
foreach(model IN LISTS ALL_MODEL_FILES)
90-
get_filename_component(modelName "${model}" NAME)
91-
STRING(REGEX MATCH "([0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9])" date "${modelName}")
92-
STRING(REGEX REPLACE "-[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9].normal.json" "" svc "${modelName}")
93-
#special svc name conversion, e.g: runtime.lex->lex; abc.def.ghi->ghi-def-abc
94-
if ("${svc}" STREQUAL "runtime.lex")
95-
LIST(APPEND C2J_SPECIAL_NAME_LIST "lex:runtime.lex")
96-
set(svc "lex")
97-
elseif("${svc}" STREQUAL "runtime.lex.v2")
98-
LIST(APPEND C2J_SPECIAL_NAME_LIST "lexv2-runtime:runtime.lex.v2")
99-
set(svc "lexv2-runtime")
100-
elseif("${svc}" STREQUAL "models.lex.v2")
101-
LIST(APPEND C2J_SPECIAL_NAME_LIST "lexv2-models:models.lex.v2")
102-
set(svc "lexv2-models")
103-
elseif ("${svc}" STREQUAL "transfer")
104-
LIST(APPEND C2J_SPECIAL_NAME_LIST "awstransfer:transfer")
105-
set(svc "awstransfer")
106-
elseif ("${svc}" STREQUAL "transcribe-streaming")
107-
LIST(APPEND C2J_SPECIAL_NAME_LIST "transcribestreaming:transcribe-streaming")
108-
set(svc "transcribestreaming")
109-
elseif ("${svc}" STREQUAL "streams.dynamodb")
110-
LIST(APPEND C2J_SPECIAL_NAME_LIST "dynamodbstreams:streams.dynamodb")
111-
set (svc "dynamodbstreams")
112-
elseif("${svc}" MATCHES "\\.")
113-
string(REPLACE "." ";" nameParts ${svc})
114-
LIST(REVERSE nameParts)
115-
string(REPLACE ";" "-" tmpSvc "${nameParts}")
116-
LIST(APPEND C2J_SPECIAL_NAME_LIST "${tmpSvc}:${svc}")
117-
set(svc "${tmpSvc}")
118-
elseif("${svc}" STREQUAL "ec2")
119-
if(PLATFORM_ANDROID AND CMAKE_HOST_WIN32) # ec2 isn't building for android on windows atm due to an internal compiler error, TODO: investigate further
120-
continue()
121-
endif()
122-
elseif("${svc}" STREQUAL "s3")
123-
LIST(APPEND C2J_SPECIAL_NAME_LIST "s3-crt:s3")
124-
message(STATUS "Add s3-crt:s3 to C2J_SPECIAL_NAME_LIST")
125-
endif()
126-
get_map_element(${svc} existingDate ${C2J_LIST})
127-
if ("${existingDate}" STREQUAL "")
128-
LIST(APPEND C2J_LIST "${svc}:${date}")
129-
if ("${svc}" STREQUAL "s3")
130-
LIST(APPEND C2J_LIST "s3-crt:${date}")
131-
endif()
132-
elseif(${existingDate} STRLESS ${date})
133-
LIST(REMOVE_ITEM C2J_LIST "${svc}:${existingDate}")
134-
LIST(APPEND C2J_LIST "${svc}:${date}")
135-
if ("${svc}" STREQUAL "s3")
136-
LIST(REMOVE_ITEM C2J_LIST "s3-crt:${existingDate}")
137-
LIST(APPEND C2J_LIST "s3-crt:${date}")
138-
endif()
139-
endif()
66+
set(LIST_DIRECTORIES true)
67+
file(GLOB ALL_GENERATED_CLIENTS $LIST_DIRECTORIES "${CMAKE_CURRENT_SOURCE_DIR}/generated/src/aws-cpp-sdk-*")
68+
69+
foreach(clientDir IN LISTS ALL_GENERATED_CLIENTS)
70+
get_filename_component(clientDirName "${clientDir}" NAME)
71+
STRING(REGEX REPLACE "^aws-cpp-sdk-" "" serviceName "${clientDirName}")
72+
LIST(APPEND SERVICE_CLIENT_LIST "${serviceName}")
14073
endforeach()
141-
set(C2J_LIST "${C2J_LIST}" PARENT_SCOPE)
142-
set(C2J_SPECIAL_NAME_LIST "${C2J_SPECIAL_NAME_LIST}" PARENT_SCOPE)
74+
set(SERVICE_CLIENT_LIST "${SERVICE_CLIENT_LIST}" PARENT_SCOPE)
14375
endfunction()
14476

145-
77+
# A list of so-called "hand-written SDK high-level libraries/components"
14678
set(HIGH_LEVEL_SDK_LIST "")
14779
list(APPEND HIGH_LEVEL_SDK_LIST "access-management")
14880
list(APPEND HIGH_LEVEL_SDK_LIST "identity-management")
@@ -151,6 +83,7 @@ list(APPEND HIGH_LEVEL_SDK_LIST "transfer")
15183
list(APPEND HIGH_LEVEL_SDK_LIST "s3-encryption")
15284
list(APPEND HIGH_LEVEL_SDK_LIST "text-to-speech")
15385

86+
# A flatmap list of sdk_component:sdk_component_tests,sdk_component_another_tests
15487
set(SDK_TEST_PROJECT_LIST "")
15588
list(APPEND SDK_TEST_PROJECT_LIST "cloudfront:tests/aws-cpp-sdk-cloudfront-integration-tests")
15689
list(APPEND SDK_TEST_PROJECT_LIST "cognito-identity:tests/aws-cpp-sdk-cognitoidentity-integration-tests")
@@ -184,11 +117,9 @@ build_sdk_list()
184117

185118
if(EXISTS "${CMAKE_SOURCE_DIR}/generated")
186119
if(EXISTS "${CMAKE_SOURCE_DIR}/generated/tests")
187-
foreach(GENERATED_C2J_TEST IN LISTS C2J_LIST)
188-
STRING(REGEX REPLACE "([^:]+):.*" "\\1" GENERATED_C2J_TEST_RESULT ${GENERATED_C2J_TEST})
189-
190-
if(EXISTS "${CMAKE_SOURCE_DIR}/generated/tests/${GENERATED_C2J_TEST_RESULT}-gen-tests")
191-
list(APPEND SDK_TEST_PROJECT_LIST "${GENERATED_C2J_TEST_RESULT}:generated/tests/${GENERATED_C2J_TEST_RESULT}-gen-tests")
120+
foreach(SERVICE_NAME IN LISTS SERVICE_CLIENT_LIST)
121+
if(EXISTS "${CMAKE_SOURCE_DIR}/generated/tests/${SERVICE_NAME}-gen-tests")
122+
list(APPEND SDK_TEST_PROJECT_LIST "${SERVICE_NAME}:generated/tests/${SERVICE_NAME}-gen-tests")
192123
endif()
193124
endforeach()
194125
endif()
@@ -213,10 +144,7 @@ list(APPEND TEST_DEPENDENCY_LIST "text-to-speech:polly,core")
213144
list(APPEND TEST_DEPENDENCY_LIST "transfer:s3,core")
214145
list(APPEND TEST_DEPENDENCY_LIST "logs:access-management,cognito-identity,iam,core")
215146

216-
# make a list of the generated clients
217-
set(GENERATED_SERVICE_LIST "")
218-
foreach(GENERATED_C2J_SERVICE IN LISTS C2J_LIST)
219-
STRING(REGEX REPLACE "([^:]+):.*" "\\1" SERVICE_RESULT ${GENERATED_C2J_SERVICE})
220-
list(APPEND GENERATED_SERVICE_LIST ${SERVICE_RESULT})
221-
list(APPEND SDK_DEPENDENCY_LIST "${SERVICE_RESULT}:core")
147+
set(GENERATED_SERVICE_LIST ${SERVICE_CLIENT_LIST})
148+
foreach(SERVICE_NAME IN LISTS SERVICE_CLIENT_LIST)
149+
list(APPEND SDK_DEPENDENCY_LIST "${SERVICE_NAME}:core")
222150
endforeach()

generated/smoke-tests/codepipeline/CodePipelineSmokeTests.cpp

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
#include <aws/testing/AwsTestHelpers.h>
1818
#include <aws/codepipeline/CodePipelineClient.h>
1919
#include <aws/codepipeline/model/GetPipelineRequest.h>
20-
#include <aws/core/utils/memory/stl/AWSString.h>
2120
#include <aws/codepipeline/model/ListPipelinesRequest.h>
2221

2322
namespace CodePipelineSmokeTest{
@@ -32,7 +31,7 @@ class CodePipelineSmokeTestSuite : public Aws::Testing::AwsCppSdkGTestSuite {
3231
static const char ALLOCATION_TAG[];
3332
};
3433
const char CodePipelineSmokeTestSuite::ALLOCATION_TAG[] = "CodePipelineSmokeTest";
35-
TEST_F(CodePipelineSmokeTestSuite, ListPipelinesSuccess )
34+
TEST_F(CodePipelineSmokeTestSuite, GetPipelineFailure )
3635
{
3736
Aws::CodePipeline::CodePipelineClientConfiguration clientConfiguration;
3837
clientConfiguration.region = "us-west-2";
@@ -41,11 +40,12 @@ TEST_F(CodePipelineSmokeTestSuite, ListPipelinesSuccess )
4140
auto clientSp = Aws::MakeShared<CodePipelineClient>(ALLOCATION_TAG, clientConfiguration);
4241
//populate input params
4342

44-
ListPipelinesRequest input;
45-
auto outcome = clientSp->ListPipelines(input);
46-
EXPECT_TRUE( outcome.IsSuccess());
43+
GetPipelineRequest input;
44+
input.SetName("fake-pipeline");
45+
auto outcome = clientSp->GetPipeline(input);
46+
EXPECT_FALSE( outcome.IsSuccess());
4747
}
48-
TEST_F(CodePipelineSmokeTestSuite, GetPipelineFailure )
48+
TEST_F(CodePipelineSmokeTestSuite, ListPipelinesSuccess )
4949
{
5050
Aws::CodePipeline::CodePipelineClientConfiguration clientConfiguration;
5151
clientConfiguration.region = "us-west-2";
@@ -54,9 +54,8 @@ TEST_F(CodePipelineSmokeTestSuite, GetPipelineFailure )
5454
auto clientSp = Aws::MakeShared<CodePipelineClient>(ALLOCATION_TAG, clientConfiguration);
5555
//populate input params
5656

57-
GetPipelineRequest input;
58-
input.SetName("fake-pipeline");
59-
auto outcome = clientSp->GetPipeline(input);
60-
EXPECT_FALSE( outcome.IsSuccess());
57+
ListPipelinesRequest input;
58+
auto outcome = clientSp->ListPipelines(input);
59+
EXPECT_TRUE( outcome.IsSuccess());
6160
}
6261
}

generated/smoke-tests/directory-service-data/DirectoryServiceDataSmokeTests.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class DirectoryServiceDataSmokeTestSuite : public Aws::Testing::AwsCppSdkGTestSu
3232
static const char ALLOCATION_TAG[];
3333
};
3434
const char DirectoryServiceDataSmokeTestSuite::ALLOCATION_TAG[] = "DirectoryServiceDataSmokeTest";
35-
TEST_F(DirectoryServiceDataSmokeTestSuite, DescribeGroupFailure )
35+
TEST_F(DirectoryServiceDataSmokeTestSuite, DescribeUserFailure )
3636
{
3737
Aws::DirectoryServiceData::DirectoryServiceDataClientConfiguration clientConfiguration;
3838
clientConfiguration.region = "us-west-2";
@@ -41,13 +41,13 @@ TEST_F(DirectoryServiceDataSmokeTestSuite, DescribeGroupFailure )
4141
auto clientSp = Aws::MakeShared<DirectoryServiceDataClient>(ALLOCATION_TAG, clientConfiguration);
4242
//populate input params
4343

44-
DescribeGroupRequest input;
44+
DescribeUserRequest input;
4545
input.SetDirectoryId("d-1111111111");
46-
input.SetSAMAccountName("test-group");
47-
auto outcome = clientSp->DescribeGroup(input);
46+
input.SetSAMAccountName("test-user");
47+
auto outcome = clientSp->DescribeUser(input);
4848
EXPECT_FALSE( outcome.IsSuccess());
4949
}
50-
TEST_F(DirectoryServiceDataSmokeTestSuite, DescribeUserFailure )
50+
TEST_F(DirectoryServiceDataSmokeTestSuite, DescribeGroupFailure )
5151
{
5252
Aws::DirectoryServiceData::DirectoryServiceDataClientConfiguration clientConfiguration;
5353
clientConfiguration.region = "us-west-2";
@@ -56,10 +56,10 @@ TEST_F(DirectoryServiceDataSmokeTestSuite, DescribeUserFailure )
5656
auto clientSp = Aws::MakeShared<DirectoryServiceDataClient>(ALLOCATION_TAG, clientConfiguration);
5757
//populate input params
5858

59-
DescribeUserRequest input;
59+
DescribeGroupRequest input;
6060
input.SetDirectoryId("d-1111111111");
61-
input.SetSAMAccountName("test-user");
62-
auto outcome = clientSp->DescribeUser(input);
61+
input.SetSAMAccountName("test-group");
62+
auto outcome = clientSp->DescribeGroup(input);
6363
EXPECT_FALSE( outcome.IsSuccess());
6464
}
6565
}

generated/smoke-tests/kinesis/KinesisSmokeTests.cpp

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
#include <aws/kinesis/KinesisClient.h>
1919
#include <aws/kinesis/model/ListStreamsRequest.h>
2020
#include <aws/kinesis/model/DescribeStreamRequest.h>
21-
#include <aws/core/utils/memory/stl/AWSString.h>
2221

2322
namespace KinesisSmokeTest{
2423
using namespace Aws::Auth;
@@ -32,7 +31,7 @@ class KinesisSmokeTestSuite : public Aws::Testing::AwsCppSdkGTestSuite {
3231
static const char ALLOCATION_TAG[];
3332
};
3433
const char KinesisSmokeTestSuite::ALLOCATION_TAG[] = "KinesisSmokeTest";
35-
TEST_F(KinesisSmokeTestSuite, ListStreamsSuccess )
34+
TEST_F(KinesisSmokeTestSuite, DescribeStreamFailure )
3635
{
3736
Aws::Kinesis::KinesisClientConfiguration clientConfiguration;
3837
clientConfiguration.region = "us-west-2";
@@ -41,11 +40,12 @@ TEST_F(KinesisSmokeTestSuite, ListStreamsSuccess )
4140
auto clientSp = Aws::MakeShared<KinesisClient>(ALLOCATION_TAG, clientConfiguration);
4241
//populate input params
4342

44-
ListStreamsRequest input;
45-
auto outcome = clientSp->ListStreams(input);
46-
EXPECT_TRUE( outcome.IsSuccess());
43+
DescribeStreamRequest input;
44+
input.SetStreamName("bogus-stream-name");
45+
auto outcome = clientSp->DescribeStream(input);
46+
EXPECT_FALSE( outcome.IsSuccess());
4747
}
48-
TEST_F(KinesisSmokeTestSuite, DescribeStreamFailure )
48+
TEST_F(KinesisSmokeTestSuite, ListStreamsSuccess )
4949
{
5050
Aws::Kinesis::KinesisClientConfiguration clientConfiguration;
5151
clientConfiguration.region = "us-west-2";
@@ -54,9 +54,8 @@ TEST_F(KinesisSmokeTestSuite, DescribeStreamFailure )
5454
auto clientSp = Aws::MakeShared<KinesisClient>(ALLOCATION_TAG, clientConfiguration);
5555
//populate input params
5656

57-
DescribeStreamRequest input;
58-
input.SetStreamName("bogus-stream-name");
59-
auto outcome = clientSp->DescribeStream(input);
60-
EXPECT_FALSE( outcome.IsSuccess());
57+
ListStreamsRequest input;
58+
auto outcome = clientSp->ListStreams(input);
59+
EXPECT_TRUE( outcome.IsSuccess());
6160
}
6261
}

generated/smoke-tests/logs/CloudWatchLogsSmokeTests.cpp

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
#include <aws/logs/model/DescribeLogGroupsRequest.h>
1919
#include <aws/logs/model/GetLogEventsRequest.h>
2020
#include <aws/logs/CloudWatchLogsClient.h>
21+
#include <aws/core/utils/memory/stl/AWSString.h>
2122

2223
namespace CloudWatchLogsSmokeTest{
2324
using namespace Aws::Auth;
@@ -31,7 +32,7 @@ class CloudWatchLogsSmokeTestSuite : public Aws::Testing::AwsCppSdkGTestSuite {
3132
static const char ALLOCATION_TAG[];
3233
};
3334
const char CloudWatchLogsSmokeTestSuite::ALLOCATION_TAG[] = "CloudWatchLogsSmokeTest";
34-
TEST_F(CloudWatchLogsSmokeTestSuite, GetLogEventsFailure )
35+
TEST_F(CloudWatchLogsSmokeTestSuite, DescribeLogGroupsSuccess )
3536
{
3637
Aws::CloudWatchLogs::CloudWatchLogsClientConfiguration clientConfiguration;
3738
clientConfiguration.region = "us-west-2";
@@ -40,13 +41,11 @@ TEST_F(CloudWatchLogsSmokeTestSuite, GetLogEventsFailure )
4041
auto clientSp = Aws::MakeShared<CloudWatchLogsClient>(ALLOCATION_TAG, clientConfiguration);
4142
//populate input params
4243

43-
GetLogEventsRequest input;
44-
input.SetLogGroupName("fakegroup");
45-
input.SetLogStreamName("fakestream");
46-
auto outcome = clientSp->GetLogEvents(input);
47-
EXPECT_FALSE( outcome.IsSuccess());
44+
DescribeLogGroupsRequest input;
45+
auto outcome = clientSp->DescribeLogGroups(input);
46+
EXPECT_TRUE( outcome.IsSuccess());
4847
}
49-
TEST_F(CloudWatchLogsSmokeTestSuite, DescribeLogGroupsSuccess )
48+
TEST_F(CloudWatchLogsSmokeTestSuite, GetLogEventsFailure )
5049
{
5150
Aws::CloudWatchLogs::CloudWatchLogsClientConfiguration clientConfiguration;
5251
clientConfiguration.region = "us-west-2";
@@ -55,8 +54,10 @@ TEST_F(CloudWatchLogsSmokeTestSuite, DescribeLogGroupsSuccess )
5554
auto clientSp = Aws::MakeShared<CloudWatchLogsClient>(ALLOCATION_TAG, clientConfiguration);
5655
//populate input params
5756

58-
DescribeLogGroupsRequest input;
59-
auto outcome = clientSp->DescribeLogGroups(input);
60-
EXPECT_TRUE( outcome.IsSuccess());
57+
GetLogEventsRequest input;
58+
input.SetLogGroupName("fakegroup");
59+
input.SetLogStreamName("fakestream");
60+
auto outcome = clientSp->GetLogEvents(input);
61+
EXPECT_FALSE( outcome.IsSuccess());
6162
}
6263
}

0 commit comments

Comments
 (0)