You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Updated gradle to 9.5.0
* Updated CI scripts with --no-daemon, --build-cache, and --max-workers=2 flags
* Refactored Semaphore CI caching strategy and separated checksums
* wip
* Refactored CI scripts for improved robustness and emulator handling
- Updated shebangs to `#!/usr/bin/env bash` and added `set -euo pipefail` for better error handling.
- Improved emulator setup in `ci-setup-and-run-emulator.sh` by ensuring a fresh AVD state and configuring hardware parameters like RAM and GPU.
- Optimized `ci-wait-for-emulator.sh` with more reliable boot completion checks and a retry loop for internet connectivity.
- Added existence checks for directories and files in artifact and test result publishing scripts to prevent errors when files are missing.
- Cleaned up redundant script headers and refactored argument handling in instrumentation test scripts.
* Removed --max-workers=2 from CI scripts and semaphore configuration
* Removed native and redundant build caches from Semaphore configuration
* Removed ninja-build installation from semaphore.yml
* Configured emulator DNS server and added resolution checks in CI scripts
* Replaced -dns-server flag with /etc/hosts entries in emulator CI scripts
* Removed hosts file modifications and adb remount from ci-wait-for-emulator.sh
* Updated ci-wait-for-emulator.sh to restart adb if root fails
* Updated ci-setup-and-run-emulator.sh to use avdmanager for AVD deletion
* Commented out debug logging in ci-setup-and-run-emulator.sh
* Added DNS initialization check to ci-wait-for-emulator.sh
* Updated ci-wait-for-emulator.sh to increase ping attempts and remove DNS property checks
* Added network diagnostic logging and improved ping verification in ci-wait-for-emulator.sh
* Enabled HTTP logging and updated CI configuration to run debug instrumentation tests
* Refactored ci-wait-for-emulator.sh to improve network setup and verification
* Added CI failure debug script and updated Semaphore configuration
* Add Ubuntu 24.04 Docker image for Android emulator SDK environment
* Refactor Android emulator setup into shared scripts
* Refactoring
* Slipped KVM for Docker image
* Modified Dockerfile
* Modified Dockerfile
* Modified Dockerfile
* Added docker/HttpsTestWebServer
* Updated docker/TestEnvironment
* ci(android): replace emulator iptables setup with /system/etc/hosts routing for flowcrypt.test domains
* ci(semaphore): redirect local HTTPS traffic from 443 to mock server on 1212 for emulator UI tests
* ci(semaphore): fix emulator routing by redirecting 10.0.2.2:443 to 1212 and add fes.flowcrypt.test host mapping
* docker(https-test-webserver): run dnsmasq alongside nginx and expose host DNS for *.flowcrypt.test
- install dnsmasq in HttpsTestWebServer image
- add dnsmasq config mapping *.flowcrypt.test to 127.0.0.1
- add entrypoint to start dnsmasq and nginx in one container
- switch run.sh to host networking with NET_ADMIN/NET_BIND_SERVICE
- expose DNS ports (53 tcp/udp) and HTTPS (443)
* Modified ci-after-fail-debug.sh
* Restored some files
* ci(android): force emulator DNS via host and harden 443->1212 redirect for flowcrypt.test tests
* Improved ci-after-fail-debug.sh
* Added ci-setup-DNS.sh
* Fix ci-setup-DNS.sh usage on CI
* Fixed ci-setup-DNS.sh
* Modified ci-wait-for-emulator.sh
* Modified ci-wait-for-emulator.sh and run-emulator.sh
* wip
* Restored ci-instrumentation-tests-flaky.sh
* Restored build.gradle.kts
* i(dns): align HttpsTestWebServer dnsmasq with CI DNS setup and add startup DNS checks
* Restored some configurations in semaphore.yml
* Updated gradle to 9.5.1
* Improved ci-wait-for-emulator.sh
* docker(test-env): route emulator DNS via host dnsmasq and document host-network adb behavior
* Temporary disabled ComposeScreenPasswordProtectedDisallowedTermsReFetchConfigurationFlowTest.kt
* Improved ci-wait-for-emulator.sh
* Updated docker/TestEnvironment/Dockerfile
* docs(readme): align DNS test setup docs with ci-setup-DNS.sh
Alternative: docs: replace manual dnsmasq steps with ci-setup-DNS.sh usage
* docs(readme): fixed redundant git difference
* switched to use -gpu auto for emulators on CI
Copy file name to clipboardExpand all lines: FlowCrypt/src/androidTest/java/com/flowcrypt/email/ui/gmailapi/passwordprotected/ComposeScreenPasswordProtectedDisallowedTermsReFetchConfigurationFlowTest.kt
Copy file name to clipboardExpand all lines: README.md
+9-7Lines changed: 9 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,18 +15,20 @@ This guide follows Google's recommendations for [testing apps on Android](https:
15
15
Please follow these steps to setup your virtual or physical device:
16
16
17
17
-[Set up your test environment](https://developer.android.com/training/testing/espresso/setup#set-up-environment).
18
-
- Some of the tests use [MockWebServer](https://github.com/square/okhttp/tree/master/mockwebserver). We run a local mock web server via [FlowCryptMockWebServerRule](https://github.com/FlowCrypt/flowcrypt-android/blob/master/FlowCrypt/src/androidTest/java/com/flowcrypt/email/rules/FlowCryptMockWebServerRule.kt). It uses [TestConstants.MOCK_WEB_SERVER_PORT](https://github.com/FlowCrypt/flowcrypt-android/blob/master/FlowCrypt/src/androidTest/java/com/flowcrypt/email/TestConstants.kt#L19) as a port. Unfortunately, the Android system doesn't allow us to use the `HTTPS 433` port by default to run a web server on the `localhost (127.0.0.1)`. That's why we have to run a mock web server on another port (for example, `1212`) and route all traffic from `127.0.0.1:433` to `127.0.0.1:1212`. For that purpose, you can use the [script/ci-wait-for-emulator.sh](https://github.com/FlowCrypt/flowcrypt-android/blob/master/script/ci-wait-for-emulator.sh#L13) script.
18
+
- Some of the tests use [MockWebServer](https://github.com/square/okhttp/tree/master/mockwebserver). We run a local mock web server via [FlowCryptMockWebServerRule](https://github.com/FlowCrypt/flowcrypt-android/blob/master/FlowCrypt/src/androidTest/java/com/flowcrypt/email/rules/FlowCryptMockWebServerRule.kt). It uses [TestConstants.MOCK_WEB_SERVER_PORT](https://github.com/FlowCrypt/flowcrypt-android/blob/master/FlowCrypt/src/androidTest/java/com/flowcrypt/email/TestConstants.kt#L19) as a port. Unfortunately, the Android system doesn't allow us to use the `HTTPS 443` port by default to run a web server on the `localhost (127.0.0.1)`. That's why we have to run a mock web server on another port (for example, `1212`) and route all traffic from `127.0.0.1:443` to `127.0.0.1:1212`. For that purpose, you can use the [script/ci-wait-for-emulator.sh](https://github.com/FlowCrypt/flowcrypt-android/blob/master/script/ci-wait-for-emulator.sh#L13) script.
19
19
- Additionally, the test environment should handle all requests to `*.flowcrypt.test`. All traffic to `*.flowcrypt.test` should be routed to `localhost (127.0.0.1)`. You can use a DNS server to do this. For example, using these commands:
20
20
21
21
```bash
22
-
1. sudo apt install -y dnsmasq resolvconf
23
-
2. echo"#added by flowcrypt"| sudo tee -a /etc/dnsmasq.conf
24
-
3. echo"listen-address=127.0.0.1"| sudo tee -a /etc/dnsmasq.conf
25
-
4. echo"address=/flowcrypt.test/127.0.0.1"| sudo tee -a /etc/dnsmasq.conf
26
-
5. echo"address=/localhost/127.0.0.1"| sudo tee -a /etc/dnsmasq.conf
27
-
6. sudo systemctl restart dnsmasq
22
+
./script/ci-setup-DNS.sh
28
23
```
29
24
25
+
The script:
26
+
- Installs `dnsmasq` and `dnsutils`.
27
+
- Creates `/etc/dnsmasq.d/flowcrypt.conf` with local rules for `*.test` and `*.localhost`.
28
+
- Sets `no-resolv` with upstream DNS servers (`8.8.8.8` and `1.1.1.1`).
29
+
- Sets `/etc/resolv.conf` to `nameserver 127.0.0.1`.
30
+
- Restarts `dnsmasq` and verifies resolution with `dig` and `ping`.
0 commit comments