-
Notifications
You must be signed in to change notification settings - Fork 0
Building the project
You can clone this repository with 'Git' to your local system. Another way is to download the zip file containing the current version (using the following link or by clicking the "Download ZIP" button on the repo page).
This library is build with the IntelliJ IDEA IDE. You can directly open and run the project from inside the IDE. You can use the 'community edition' to build the project. For other IDEs you have to adapt the project accordingly.
This project uses Docker as build and testing environment tool. If you simply want to use the build scripts and tests without adding additional tools manually you should have a locally installed Docker instance running and added to your path.
You can find further instructions here on how to install Docker for linux and for windows
This project uses yarn as it's build management tool.
To install all necessary dependencies, you can run:
yarn install
The api classes are generated via java and maven directly from webPDFs openapi.json. To do this you can either use locally installed java and maven and then simply run mvn clean package in the codegen folder using the pom.xml.
Or you could use the build script depending on Docker to produce all necessary files and simply run:
yarn run build
To test the client-server communication with the webPDF server itself, you will have to create and edit the "config/testConfig.json" accordingly (you can find an example configuration in "config/testConfig-sample.json"), that allows you to enable, configure or disable the following extended test groups:
- integration: Attempt to execute sample requests to the public webPDF demo server and a local custom test webPDF Server, that the user provides.
- oauth: Attempt to connect to the local custom test webPDF Server using OAuth2 tokens.
- proxy: Assumes a client-side proxy to be present and uses the provided proxy configuration to check whether the routing works as expected.
- ldap: Assumes a ldap server to be present and uses the provided user configuration to check whether the user handling works as expected.
- tls: Assumes a https connection is usable for the configured webPDF server and checks wether the secured connection works as intended.
If the useContainer option is enabled for integration tests a local Docker image will be deployed with proxy, ldap and webPDF server already deployed and ready for testing.
Make sure, to enter the different configurable options in a manner, that matches your webPDF server configuration, otherwise such Tests should remain disabled, as they must be expected to fail. (e.g. don´t attempt to connect to the server´s HTTPS port, should you not have added such a port to your webPDF server.)
Also: Once enabled the tests expect, that you provide valid selections for all predefined attributes without fail.
Recommendation: All extended test groups are mostly intended for usage during the integration testing of this library on our side. It is recommended to not enable those test.
Be aware: The OAuth tests assume, that you configured Azure aswell as Auth0 authorization for your webPDF test server and can provide matching tokens, that can be used.
Also be aware: As some integration tests attempt to connect to our public demo portal such tests require an active internet connection.