Skip to content

Commit

Permalink
Fix unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
chashikajw committed Oct 11, 2023
1 parent 084b6c0 commit 75ce98d
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ dependencies = [
[[package]]
org = "ballerina"
name = "http"
version = "2.10.1"
version = "2.10.2"
dependencies = [
{org = "ballerina", name = "auth"},
{org = "ballerina", name = "cache"},
Expand Down
8 changes: 4 additions & 4 deletions backoffice/backoffice-domain-service/ballerina/types.bal
Original file line number Diff line number Diff line change
Expand Up @@ -74,15 +74,15 @@ public type Document record {
string documentId?;
@constraint:String {maxLength: 60, minLength: 1}
string name;
"HOWTO"|"SAMPLES"|"PUBLIC_FORUM"|"SUPPORT_FORUM"|"API_MESSAGE_FORMAT"|"SWAGGER_DOC"|"OTHER" documentType?;
string documentType?;
@constraint:String {maxLength: 32766, minLength: 1}
string summary?;
"INLINE"|"MARKDOWN"|"URL"|"FILE" sourceType;
string sourceType;
string sourceUrl?;
string fileName?;
string inlineContent?;
string otherTypeName?;
"OWNER_ONLY"|"PRIVATE"|"API_LEVEL" visibility;
string visibility;
string createdTime?;
string createdBy?;
string lastUpdatedTime?;
Expand Down Expand Up @@ -229,7 +229,7 @@ public type MonetizationAttribute record {
};

public type APIDefinition record {
"swagger"|"graphql"|"wsdl"|"async" 'type;
string 'type;
string schemaDefinition?;
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ dependencies = [
[[package]]
org = "ballerina"
name = "http"
version = "2.10.1"
version = "2.10.2"
dependencies = [
{org = "ballerina", name = "auth"},
{org = "ballerina", name = "cache"},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,7 @@ function getAPIDefinitionByIdTest(){
if apiDefResponse is APIDefinition {
test:assertTrue(true, "Successfully retrieved API Definition");
} else if apiDefResponse is commons:APKError {
log:printInfo(apiDefResponse.toBalString());
log:printError(apiDefResponse.toString());
test:assertFail("Error occured while retrieving API");
} else if apiDefResponse is NotFoundError {
Expand Down Expand Up @@ -223,6 +224,7 @@ function generateSDKImplTestNegative(){
if sdk is http:Response {
test:assertFail("Successfully generated API SDK");
} else if sdk is sdk:APIClientGenerationException|commons:APKError {
log:printInfo(sdk.toBalString());
test:assertTrue(true,"Error while generating API SDK");
}
}
Expand Down
2 changes: 1 addition & 1 deletion devportal/devportal-domain-service/ballerina/types.bal
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,7 @@ public type ApplicationKeyList record {
};

public type APIDefinition record {
"swagger"|"graphql"|"wsdl"|"async" 'type;
string 'type;
string schemaDefinition?;
};

Expand Down

0 comments on commit 75ce98d

Please sign in to comment.