cedar-policy / cedar-java

Java bindings for the Cedar language
https://www.cedarpolicy.com
Apache License 2.0
42 stars 19 forks source link

Update Gradle build to download integration tests #114

Closed exceptionfactory closed 7 months ago

exceptionfactory commented 7 months ago

Issue #, if available:

Description of changes:

This pull request updates the Gradle configuration to download the main branch of the Cedar repository, incorporating integration testing in the standard build. The gradle-download-task handles the HTTP request to the GitHub URL, downloading the Zip archive of the Cedar repository main branch.

Instead of setting the integration tests path from an environment variable, the Gradle tasks extract the Cedar repository archive to the build test resources directory. This approach makes the integration test corpus available as a class path resource. Updates to the SharedIntegrationTests class resolve the directory from the class path location.

Additional changes include updating the continuous integration workflow to run on both Ubuntu Linux and macOS 14. The macOS 14 runner uses AArch64 architecture. The updated workflow installs Zig using the platform-specific package manager, and also includes the setup-java action to provide a consistent vendor and version of the JDK.

exceptionfactory commented 7 months ago

Thanks for the review @khieta! I removed the Integration Testing section and also updated the main project README.md with simplified instructions for getting started.