Skip to content

Commit

Permalink
Merge pull request #1351 from hashgraph/fix-reconnect-tests
Browse files Browse the repository at this point in the history
Fix existing reconnect tests
  • Loading branch information
Neeharika-Sompalli authored Apr 30, 2021
2 parents 4f9019f + 8b7c2c2 commit ba21b64
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ protected List<HapiApiSpec> getSpecsInSuite() {
);
}

private synchronized HapiSpecOperation generateScheduleCreateOperation() {
private HapiSpecOperation generateScheduleCreateOperation() {
if (scheduleNumber.getAndIncrement() > SCHEDULE_CREATION_LIMIT) {
return getVersionInfo()
.noLogging();
Expand All @@ -88,7 +88,7 @@ private synchronized HapiSpecOperation generateScheduleCreateOperation() {
.hasAnyKnownStatus()
.deferStatusResolution()
.adminKey(DEFAULT_PAYER)
.logging()
.noLogging()
.advertisingCreation();
}

Expand Down Expand Up @@ -126,7 +126,8 @@ private HapiApiSpec runCreateSchedules() {
.hasAnyKnownStatus()
.deferStatusResolution()
.adminKey(DEFAULT_PAYER)
.logging().advertisingCreation()
.noLogging()
.advertisingCreation()
).when(
fileUpdate(APP_PROPERTIES)
.payingWith(GENESIS)
Expand All @@ -146,7 +147,7 @@ private HapiApiSpec runCreateSchedules() {
.hasAnyKnownStatus()
.deferStatusResolution()
.adminKey(DEFAULT_PAYER)
.logging().advertisingCreation(),
.noLogging().advertisingCreation(),
defaultLoadTest(createBurst, settings)
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,15 @@ protected List<HapiApiSpec> getSpecsInSuite() {
);
}

private synchronized HapiSpecOperation generateTopicCreateOperation() {
private HapiSpecOperation generateTopicCreateOperation() {
final long token = tokenNumber.getAndIncrement();
if (token >= TOKEN_CREATION_LIMIT) {
return getVersionInfo()
.noLogging();
}

return tokenCreate("token" + token)
.logging()
.noLogging()
.hasRetryPrecheckFrom(BUSY, PLATFORM_TRANSACTION_NOT_CREATED)
.hasKnownStatusFrom(SUCCESS, TOKEN_ALREADY_ASSOCIATED_TO_ACCOUNT,
TOKENS_PER_ACCOUNT_LIMIT_EXCEEDED)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@ private HapiApiSpec expireSchedulesDuringReconnect() {
.hasAnyKnownStatus()
.deferStatusResolution()
.adminKey(DEFAULT_PAYER)
.logging().advertisingCreation()
.logging()
.advertisingCreation()
.savingExpectedScheduledTxnId()
)
.when(
Expand All @@ -106,7 +107,8 @@ private HapiApiSpec expireSchedulesDuringReconnect() {
.hasAnyKnownStatus()
.deferStatusResolution()
.adminKey(DEFAULT_PAYER)
.logging().advertisingCreation()
.logging()
.advertisingCreation()
.savingExpectedScheduledTxnId(),

scheduleCreate(oneOtherSchedule,
Expand All @@ -119,7 +121,8 @@ private HapiApiSpec expireSchedulesDuringReconnect() {
.hasAnyKnownStatus()
.deferStatusResolution()
.adminKey(DEFAULT_PAYER)
.logging().advertisingCreation()
.logging()
.advertisingCreation()
.savingExpectedScheduledTxnId(),

getAccountBalance(GENESIS)
Expand Down

0 comments on commit ba21b64

Please sign in to comment.