Skip to content

Commit b242164

Browse files
authored
Merge pull request #433 from joreilly/cleanup
cleanup + iniitial Maestro UI test
2 parents 2ae7be2 + e5fc306 commit b242164

File tree

70 files changed

+277
-185
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

70 files changed

+277
-185
lines changed

.github/workflows/android.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ jobs:
88
runs-on: ubuntu-24.04
99

1010
steps:
11-
- uses: actions/checkout@v3
11+
- uses: actions/checkout@v5
1212
- name: set up JDK 17
13-
uses: actions/setup-java@v3
13+
uses: actions/setup-java@v5
1414
with:
1515
distribution: 'zulu'
1616
java-version: 17
@@ -30,10 +30,10 @@ jobs:
3030
runs-on: ubuntu-24.04
3131
steps:
3232
- name: Checkout
33-
uses: actions/checkout@v3
33+
uses: actions/checkout@v5
3434

3535
- name: Set up JDK 17
36-
uses: actions/setup-java@v3
36+
uses: actions/setup-java@v5
3737
with:
3838
distribution: 'zulu'
3939
java-version: 17

.github/workflows/ios.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ jobs:
1212
build:
1313
runs-on: macos-14
1414
steps:
15-
- uses: actions/checkout@v3
16-
- uses: actions/setup-java@v3
15+
- uses: actions/checkout@v5
16+
- uses: actions/setup-java@v5
1717
with:
1818
distribution: 'zulu'
1919
java-version: 17

.github/workflows/maestro.yml

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
name: Maestro UI tests
2+
3+
on: pull_request
4+
5+
jobs:
6+
test:
7+
runs-on: ubuntu-24.04
8+
steps:
9+
- uses: actions/checkout@v5
10+
11+
- name: Enable KVM
12+
run: |
13+
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
14+
sudo udevadm control --reload-rules
15+
sudo udevadm trigger --name-match=kvm
16+
17+
- name: Set up Gradle cache
18+
uses: gradle/actions/setup-gradle@v4
19+
20+
- uses: actions/setup-java@v5
21+
with:
22+
distribution: 'zulu'
23+
java-version: 17
24+
25+
# Cache Android SDK system images to avoid re-downloading emulator images
26+
- name: Cache Android SDK system images
27+
uses: actions/cache@v4
28+
with:
29+
path: /usr/local/lib/android/sdk/system-images
30+
key: ${{ runner.os }}-android-sdk-system-images-api-30-default-x86_64
31+
restore-keys: |
32+
${{ runner.os }}-android-sdk-system-images-
33+
34+
# Cache the AVD directory so the emulator can reuse a pre-created snapshot
35+
- name: Cache AVD
36+
uses: actions/cache@v4
37+
with:
38+
path: ~/.android/avd
39+
key: ${{ runner.os }}-avd-api-32-default-x86_64
40+
restore-keys: |
41+
${{ runner.os }}-avd-
42+
43+
# Cache Maestro CLI installation
44+
- name: Cache Maestro
45+
uses: actions/cache@v4
46+
with:
47+
path: ~/.maestro
48+
key: ${{ runner.os }}-maestro-v1
49+
restore-keys: |
50+
${{ runner.os }}-maestro-
51+
52+
- name: Build android app
53+
run: ./gradlew :app:assembleDebug
54+
55+
- uses: dniHze/maestro-test-action@v1
56+
57+
- name: Run Maestro tests
58+
uses: reactivecircus/android-emulator-runner@v2
59+
with:
60+
api-level: 32
61+
arch: x86_64
62+
profile: Nexus 6
63+
avd-name: peopleinspace-api32
64+
emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
65+
disable-animations: true
66+
script: adb install ./app/build/outputs/apk/debug/app-debug.apk && maestro test maestro/PeopleInSpace.flow
67+
68+
- uses: actions/upload-artifact@v4
69+
with:
70+
name: screenshot
71+
path: PeopleInSpace.png

.github/workflows/wearos.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ jobs:
88
runs-on: macos-14
99
steps:
1010
- name: Checkout
11-
uses: actions/checkout@v3
11+
uses: actions/checkout@v5
1212

1313
- name: Set up JDK 17
14-
uses: actions/setup-java@v3
14+
uses: actions/setup-java@v5
1515
with:
1616
distribution: 'zulu'
1717
java-version: 17

.github/workflows/web.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ jobs:
88
runs-on: ubuntu-24.04
99

1010
steps:
11-
- uses: actions/checkout@v3
11+
- uses: actions/checkout@v5
1212
- name: set up JDK 17
13-
uses: actions/setup-java@v3
13+
uses: actions/setup-java@v5
1414
with:
1515
distribution: 'zulu'
1616
java-version: 17

.junie/guidelines.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Project Guidelines
2+
3+
## Building the Project
4+
When building this project Junie should use the following Gradle task:
5+
```
6+
:common:compileDebugSources
7+
```

app/build.gradle.kts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ android {
1414
compileSdk = libs.versions.compileSdk.get().toInt()
1515

1616
defaultConfig {
17-
applicationId = "com.surrus.peopleinspace"
17+
applicationId = "dev.johnoreilly.peopleinspace"
1818
minSdk = libs.versions.minSdk.get().toInt()
1919
targetSdk = libs.versions.targetSdk.get().toInt()
2020

@@ -39,7 +39,7 @@ android {
3939
}
4040
}
4141

42-
namespace = "com.surrus.peopleinspace"
42+
namespace = "dev.johnoreilly.peopleinspace"
4343

4444
testOptions {
4545
managedDevices {

app/src/androidTest/java/com/surrus/peopleinspace/PeopleInSpaceRepositoryFake.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
package com.surrus.peopleinspace
1+
package dev.johnoreilly.peopleinspace
22

3-
import com.surrus.common.remote.Assignment
4-
import com.surrus.common.remote.IssPosition
5-
import com.surrus.common.repository.PeopleInSpaceRepositoryInterface
3+
import dev.johnoreilly.common.remote.Assignment
4+
import dev.johnoreilly.common.remote.IssPosition
5+
import dev.johnoreilly.common.repository.PeopleInSpaceRepositoryInterface
66
import kotlinx.coroutines.flow.Flow
77
import kotlinx.coroutines.flow.flowOf
88

app/src/androidTest/java/com/surrus/peopleinspace/PeopleInSpaceTest.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
package com.surrus.peopleinspace
1+
package dev.johnoreilly.peopleinspace
22

33
import androidx.compose.ui.test.*
44
import androidx.compose.ui.test.junit4.createComposeRule
5-
import com.surrus.common.viewmodel.PersonListUiState
6-
import com.surrus.peopleinspace.personlist.PersonListScreen
7-
import com.surrus.peopleinspace.personlist.PersonListTag
5+
import dev.johnoreilly.common.viewmodel.PersonListUiState
6+
import dev.johnoreilly.peopleinspace.personlist.PersonListScreen
7+
import dev.johnoreilly.peopleinspace.personlist.PersonListTag
88
import org.junit.Rule
99
import org.junit.Test
1010

app/src/main/AndroidManifest.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
</intent-filter>
2828
</activity>
2929

30-
<receiver android:name="com.surrus.peopleinspace.glance.PeopleInSpaceWidgetReceiver"
30+
<receiver android:name="dev.johnoreilly.peopleinspace.glance.PeopleInSpaceWidgetReceiver"
3131
android:label="People in Space"
3232
android:exported="true">
3333
<intent-filter>
@@ -39,7 +39,7 @@
3939
android:resource="@xml/widget_info" />
4040
</receiver>
4141

42-
<receiver android:name="com.surrus.peopleinspace.glance.ISSMapWidgetReceiver"
42+
<receiver android:name="dev.johnoreilly.peopleinspace.glance.ISSMapWidgetReceiver"
4343
android:label="ISS Map"
4444
android:exported="true">
4545
<intent-filter>

0 commit comments

Comments
 (0)