HACKING.md 2.13 KiB
Hacking guide
Running style checks and unit tests
When working on the code base, consider running the style checks and unit tests locally, because the CI will complain anyway:
./gradlew briar-desktop:check
The above command does both. To run style checks only:
./gradlew ktlintCheck
If that fails, try formatting:
./gradlew ktlintFormat
Running unit tests only:
./gradlew briar-desktop:test --tests "*"
That will run tests from the desktop project only. On the other hand, this will also run tests on briar core:
./gradlew test
Testing different locales
You can simply switch the language in the settings screen of the application.
To test the app with a different default locale, add this e.g. in Main.kt
:
Locale.setDefault(Locale("ar"))
and replace ar
with a different language you would like to test, such as
Arabic in this example.
It is also possible to run from the command line using Gradle with a different default language setting:
GRADLE_OPTS="-Duser.language=fr -Duser.country=FR" ./gradlew run