| .. | ||
| cross-test-client | ||
| cross-test-server | ||
| src/test | ||
| build.gradle.kts | ||
| CMakeLists.txt | ||
| gradle.properties | ||
| Makefile.am | ||
| README.md | ||
| settings.gradle.kts | ||
Test Only Library for Kotlin
This directory (/lib/kotlin) contains test only library code for Kotlin code gen. Because Kotlin code gen produces code that works on top of libthrift (i.e. Java library), the purpose of this library is to encode the cross test server and client to make sure it conforms to the thrift specifications.
The output artifact in this library is not published to Maven central. Unlike the Java library where:
- source code is put under
mainsources set i.e.src/main, - unit test code is put under
testsources set i.e.src/test, - cross test code is put under
crossTestsources set, i.e.src/crossTestdirectory which, unlike the defaultmainandtest, is created and configured on demand;
this kotlin library uses a multi-module project setup for separation of concern:
- root module for configuring unit tests,
cross-test-clientmodule for bundling a standalone test client,cross-test-servermodule for bundling a standalone test server
How to compile
This library is managed using Gradle 6.9.2, run the following command (requires C++ thrift compiler):
gradle build
gradle installDist
How to run cross test server / client
gradle :cross-test-server:run
gradle :cross-test-client:run