Skip to content

Commit

Permalink
Update content of the OAS file and documentation - 2023-11-14.1
Browse files Browse the repository at this point in the history
  • Loading branch information
bitbucket-automation committed Nov 14, 2023
1 parent 5a06225 commit 37cc4cb
Show file tree
Hide file tree
Showing 3 changed files with 877 additions and 144 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ All notable changes to the API definition will be recorded here.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html)

## [2.26.0] - 2023-11-14

### Added
- Added endpoints to manage applications and sub-applications (Application Management)

## [2.25.0] - 2023-09-27
### Added
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
package com.yapily.openapi.service;

import java.io.IOException;
import java.util.Base64;
import java.util.List;
import java.util.UUID;

import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
Expand All @@ -16,21 +11,11 @@
import org.openapitools.client.api.PaymentsApi;
import org.openapitools.client.api.UsersApi;
import org.openapitools.client.auth.HttpBasicAuth;
import org.openapitools.client.model.Account;
import org.openapitools.client.model.AccountAuthorisationResponse;
import org.openapitools.client.model.ApiResponseOfAccountAuthorisationResponse;
import org.openapitools.client.model.ApiResponseOfPaymentAuthorisationRequestResponse;
import org.openapitools.client.model.ApiResponseOfPaymentResponse;
import org.openapitools.client.model.ApiResponseOfUserDeleteResponse;
import org.openapitools.client.model.ApplicationUser;
import org.openapitools.client.model.NewApplicationUser;
import org.openapitools.client.model.PaymentAuthorisationRequestResponse;
import org.openapitools.client.model.PaymentRequest;
import org.openapitools.client.model.PaymentResponse;
import org.openapitools.client.model.PaymentResponses;
import org.openapitools.client.model.Transaction;
import org.openapitools.client.model.*;

import com.google.gson.JsonObject;
import java.io.IOException;
import java.util.List;
import java.util.UUID;

import static org.junit.Assert.fail;

Expand All @@ -56,7 +41,7 @@ public class SuiteTest {
void setup() {
basicAuth.setUsername(System.getenv("APP_UUID"));
basicAuth.setPassword(System.getenv("APP_SECRET"));

System.out.println("APP ID is -> ["+System.getenv("APP_UUID")+"]");
final UsersApi usersApi = new UsersApi(defaultClient);
final AuthorisationsApi authApi = new AuthorisationsApi(defaultClient);
final PaymentsApi paymentsApi = new PaymentsApi(defaultClient);
Expand Down Expand Up @@ -98,8 +83,7 @@ void testAccountFlow() {
ApiResponseOfUserDeleteResponse deletedUser = userService.deleteUser(confirmedUser.getUuid());
Assertions.assertNotNull(deletedUser);
} catch (ApiException | IOException e) {
fail("Should not have thrown exception");
e.printStackTrace();
handleException(e);
}
}

Expand Down Expand Up @@ -134,8 +118,15 @@ void testPaymentsFlow() {
ApiResponseOfUserDeleteResponse deletedUser = userService.deleteUser(confirmedUser.getUuid());
Assertions.assertNotNull(deletedUser);
} catch (ApiException | IOException e) {
fail("Should not have thrown exception");
e.printStackTrace();
handleException(e);
}
}

private static void handleException(Exception e) {
if (e instanceof ApiException) {
fail("Should not have thrown APIException: " + ((ApiException) e).getResponseBody());
} else {
fail("Should not have thrown exception: " + e.getStackTrace());
}
}
}
Loading

0 comments on commit 37cc4cb

Please sign in to comment.