Skip to content

Commit ec58561

Browse files
author
AntoniaSzecsi
committed
Update README to reflect changes
1 parent 1e47362 commit ec58561

File tree

1 file changed

+43
-0
lines changed
  • aws-lambda-java-runtime-interface-client

1 file changed

+43
-0
lines changed

aws-lambda-java-runtime-interface-client/README.md

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,49 @@ This command invokes the function running in the container image and returns a r
138138

139139
*Alternately, you can also include RIE as a part of your base image. See the AWS documentation on how to [Build RIE into your base image](https://docs.aws.amazon.com/lambda/latest/dg/images-test.html#images-test-alternative).*
140140

141+
### Automated Local Testing
142+
143+
For developers working on this runtime interface client, we provide an automated testing script that handles RIE setup, dependency management, and Docker orchestration.
144+
145+
*Prerequisites:*
146+
- Build the project first: `mvn clean install`
147+
- Docker must be installed and running
148+
149+
*To run automated tests:*
150+
151+
```shell script
152+
make test-rie
153+
```
154+
155+
This single command will:
156+
- Automatically download required dependencies (aws-lambda-java-core, aws-lambda-java-serialization)
157+
- Build a Docker image with RIE pre-installed
158+
- Compile and run a test Lambda function (EchoHandler)
159+
- Execute the function and validate the response
160+
- Clean up containers automatically
161+
162+
The test uses a simple EchoHandler that returns the input event, making it easy to verify the runtime interface client is working correctly.
163+
164+
## Test Coverage
165+
166+
This project uses JaCoCo for code coverage analysis. To exclude classes from JaCoCo coverage, add them to the `jacoco-maven-plugin` configuration:
167+
168+
```xml
169+
<plugin>
170+
<groupId>org.jacoco</groupId>
171+
<artifactId>jacoco-maven-plugin</artifactId>
172+
<configuration>
173+
<excludes>
174+
<exclude>**/*Exception.class</exclude>
175+
<exclude>**/dto/*.class</exclude>
176+
<exclude>**/YourClassName.class</exclude>
177+
</excludes>
178+
</configuration>
179+
</plugin>
180+
```
181+
182+
This project excludes by default: exceptions, interfaces, DTOs, constants, and runtime-only classes.
183+
141184
### Troubleshooting
142185

143186
While running integration tests, you might encounter the Docker Hub rate limit error with the following body:

0 commit comments

Comments
 (0)