Error While running gradlew test

./gradlew test

An error has occurred while processing the shared archive file.
Unable to unmap shared space.
Error occurred during initialization of VM
Unable to use shared archive.

how to solve this?

This error message is indicating that there is a problem with the Java Virtual Machine (JVM) and its ability to use the shared archive file. One possible solution is to increase the amount of memory allocated to the JVM by adding the -Xmx option to the command. For example:

./gradlew test -Xmx2g

This will increase the maximum heap size to 2GB.

Another solution is to disable the shared archive by adding the -Xshare:off option to the command:

./gradlew test -Xshare:off