Skip to content

Commit ba37e6d

Browse files
committed
Merge branch 'trunk' of github.com:woocommerce/woocommerce-android into AINFRA-435/test-setup-to-validate-android-agent-mac-memtal
2 parents 9794627 + d286a4c commit ba37e6d

File tree

94 files changed

+8888
-2059
lines changed

Some content is hidden

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

94 files changed

+8888
-2059
lines changed

.buildkite/commands/lint.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,6 @@ if [ $app_lint_exit_code -ne 0 ] || [ $wear_lint_exit_code -ne 0 ]; then
2020
fi
2121

2222
upload_sarif_to_github 'WooCommerce/build/reports/lint-results-jalapenoDebug.sarif'
23+
upload_sarif_to_github 'WooCommerce-Wear/build/reports/lint-results-jalapenoDebug.sarif'
2324

2425
exit $lint_exit_code

RELEASE-NOTES.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,11 @@
33
*** For entries which are touching the Android Wear app's, start entry with `[WEAR]` too.
44
22.9
55
-----
6+
- [*] Fixed infinite loading animation in Order details pane when order list is empty [https://github.com/woocommerce/woocommerce-android/pull/14316]
67
- [*] Fixed rare crash on the Payment Selection screen. [https://github.com/woocommerce/woocommerce-android/pull/14318]
78
- [**] Added option to filter orders by Point of Sale sales channel in Orders screen [https://github.com/woocommerce/woocommerce-android/pull/14286]
9+
- [*] Fixed keyboard not being shown when searching in Orders screen [https://github.com/woocommerce/woocommerce-android/pull/14344]
10+
- [*] Added POS badge to Most recent orders section in the My store dashboard [https://github.com/woocommerce/woocommerce-android/pull/14328]
811

912
22.8
1013
-----

WooCommerce-Wear/build.gradle

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,10 @@ android {
120120
}
121121
}
122122
}
123+
124+
lintOptions {
125+
checkDependencies = false
126+
}
123127
}
124128

125129
dependencies {
@@ -206,7 +210,6 @@ dependencies {
206210
// See https://github.com/wordpress-mobile/WordPress-FluxC-Android/issues/919
207211
exclude group: 'com.squareup.okhttp3'
208212
}
209-
lintChecks(libs.android.security.lint)
210213
}
211214

212215
android.buildTypes.all { buildType ->

WooCommerce-Wear/lint-baseline.xml

Lines changed: 114 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,114 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<issues format="6" by="lint 8.8.0" type="baseline" client="gradle" dependencies="false" name="AGP (8.8.0)" variant="all" version="8.8.0">
3+
4+
<issue
5+
id="DoNotMockDataClass"
6+
message="&apos;com.woocommerce.commons.WearOrderedProduct&apos; is a data class, so mocking it should not be necessary"
7+
errorLine1=" val expectedProducts = listOf&lt;WearOrderedProduct>(mock())"
8+
errorLine2=" ~~~~~~">
9+
<location
10+
file="src/test/java/com/woocommerce/android/wear/ui/orders/details/FetchOrderProductsTest.kt"
11+
line="56"
12+
column="59"/>
13+
</issue>
14+
15+
<issue
16+
id="DoNotMockDataClass"
17+
message="&apos;com.woocommerce.commons.WearOrder&apos; is a data class, so mocking it should not be necessary"
18+
errorLine1=" val expectedOrders = listOf&lt;WearOrder>(mock())"
19+
errorLine2=" ~~~~~~">
20+
<location
21+
file="src/test/java/com/woocommerce/android/wear/ui/orders/list/FetchOrdersTest.kt"
22+
line="87"
23+
column="48"/>
24+
</issue>
25+
26+
<issue
27+
id="DoNotMockDataClass"
28+
message="&apos;org.wordpress.android.fluxc.model.WCRevenueStatsModel&apos; is a data class, so mocking it should not be necessary"
29+
errorLine1=" val revenueStats = mock&lt;WCRevenueStatsModel> {"
30+
errorLine2=" ^">
31+
<location
32+
file="src/test/java/com/woocommerce/android/wear/complications/FetchStatsForComplicationsTest.kt"
33+
line="39"
34+
column="28"/>
35+
</issue>
36+
37+
<issue
38+
id="DoNotMockDataClass"
39+
message="&apos;org.wordpress.android.fluxc.model.WCRevenueStatsModel&apos; is a data class, so mocking it should not be necessary"
40+
errorLine1=" val revenueStats = mock&lt;WCRevenueStatsModel> {"
41+
errorLine2=" ^">
42+
<location
43+
file="src/test/java/com/woocommerce/android/wear/complications/FetchStatsForComplicationsTest.kt"
44+
line="68"
45+
column="28"/>
46+
</issue>
47+
48+
<issue
49+
id="DoNotMockDataClass"
50+
message="&apos;org.wordpress.android.fluxc.model.WCRevenueStatsModel&apos; is a data class, so mocking it should not be necessary"
51+
errorLine1=" val revenueResponse = mock&lt;WCRevenueStatsModel> {"
52+
errorLine2=" ^">
53+
<location
54+
file="src/test/java/com/woocommerce/android/wear/ui/stats/datasource/FetchStatsTest.kt"
55+
line="110"
56+
column="31"/>
57+
</issue>
58+
59+
<issue
60+
id="DoNotMockDataClass"
61+
message="&apos;org.wordpress.android.fluxc.persistence.entity.OrderEntity&apos; is a data class, so mocking it should not be necessary"
62+
errorLine1=" val order1 = mock&lt;OrderEntity> { on { dateCreated } doReturn &quot;1000&quot; }"
63+
errorLine2=" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
64+
<location
65+
file="src/test/java/com/woocommerce/android/wear/ui/orders/OrdersRepositoryTest.kt"
66+
line="37"
67+
column="22"/>
68+
</issue>
69+
70+
<issue
71+
id="DoNotMockDataClass"
72+
message="&apos;org.wordpress.android.fluxc.persistence.entity.OrderEntity&apos; is a data class, so mocking it should not be necessary"
73+
errorLine1=" val order2 = mock&lt;OrderEntity> { on { dateCreated } doReturn &quot;2000&quot; }"
74+
errorLine2=" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
75+
<location
76+
file="src/test/java/com/woocommerce/android/wear/ui/orders/OrdersRepositoryTest.kt"
77+
line="38"
78+
column="22"/>
79+
</issue>
80+
81+
<issue
82+
id="DoNotMockDataClass"
83+
message="&apos;org.wordpress.android.fluxc.persistence.entity.OrderEntity&apos; is a data class, so mocking it should not be necessary"
84+
errorLine1=" val order3 = mock&lt;OrderEntity> { on { dateCreated } doReturn &quot;1500&quot; }"
85+
errorLine2=" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
86+
<location
87+
file="src/test/java/com/woocommerce/android/wear/ui/orders/OrdersRepositoryTest.kt"
88+
line="39"
89+
column="22"/>
90+
</issue>
91+
92+
<issue
93+
id="DoNotMockDataClass"
94+
message="&apos;com.woocommerce.android.wear.settings.AppSettings.CrashReportEnabledSettings&apos; is a data class, so mocking it should not be necessary"
95+
errorLine1=" val settingsMock = mock&lt;CrashReportEnabledSettings>()"
96+
errorLine2=" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
97+
<location
98+
file="src/test/java/com/woocommerce/android/wear/crashlogging/WCWearCrashLoggingDataProviderTest.kt"
99+
line="63"
100+
column="28"/>
101+
</issue>
102+
103+
<issue
104+
id="DoNotMockDataClass"
105+
message="&apos;com.woocommerce.android.wear.settings.AppSettings.CrashReportEnabledSettings&apos; is a data class, so mocking it should not be necessary"
106+
errorLine1=" val settingsMock = mock&lt;CrashReportEnabledSettings>()"
107+
errorLine2=" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
108+
<location
109+
file="src/test/java/com/woocommerce/android/wear/crashlogging/WCWearCrashLoggingDataProviderTest.kt"
110+
line="74"
111+
column="28"/>
112+
</issue>
113+
114+
</issues>

WooCommerce-Wear/proguard-rules.pro

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,6 @@
6868
-keep class uk.co.senab.photoview.** { *; }
6969
###### Zendesk - end
7070

71-
###### Encrypted Logs - begin
72-
-dontwarn java.awt.*
73-
-keep class com.sun.jna.* { *; }
74-
-keepclassmembers class * extends com.sun.jna.* { public *; }
75-
###### Encrypted Logs - end
76-
7771
###### Glide - begin
7872
-keep class com.bumptech.glide.GeneratedAppGlideModuleImpl { *; }
7973
###### Glide - end

WooCommerce/build.gradle

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,17 @@ fladle {
1919
variant = "vanillaDebug"
2020
serviceAccountCredentials = rootProject.file(".configure-files/firebase.secrets.json")
2121
testTargets = [
22-
"notPackage com.woocommerce.android.e2e"
22+
"notPackage com.woocommerce.android.e2e.tests.screenshot"
2323
]
2424
devices = [
25-
["model": "Pixel2.arm", "version": "30"]
25+
["model": "MediumPhone.arm", "version": "35"]
2626
]
2727
localResultsDir = "$rootDir/build/instrumented-tests"
2828

29+
useOrchestrator = true
30+
testTimeout = "5m"
31+
flakyTestAttempts = 1
32+
2933
maxTestShards = 50
3034
shardTime = 120
3135
smartFlankGcsPath = "gs://fladle/woocommerce-android/smart-flank/JUnitReport.xml"
@@ -79,6 +83,7 @@ android {
7983
targetSdkVersion gradle.ext.targetSdkVersion
8084

8185
testInstrumentationRunner 'com.woocommerce.android.WooCommerceTestRunner'
86+
testInstrumentationRunnerArguments clearPackageData: 'true'
8287
// TODO remove this once the hilt migration is complete
8388
javaCompileOptions.annotationProcessorOptions.arguments['dagger.hilt.disableModulesHaveInstallInCheck'] = 'true'
8489

@@ -164,13 +169,12 @@ android {
164169
}
165170

166171
lintOptions {
167-
sarifReport = gradle.ext.isCi
168172
checkDependencies = true
169-
disable 'InvalidPackage'
170173
}
171174

172175
testOptions {
173176
animationsDisabled = true
177+
execution 'ANDROIDX_TEST_ORCHESTRATOR'
174178
}
175179

176180
signingConfigs {
@@ -241,6 +245,7 @@ dependencies {
241245
exclude group: "com.android.support"
242246
}
243247

248+
implementation(libs.automattic.encryptedlogging)
244249
implementation(libs.automattic.tracks.experimentation)
245250
implementation(libs.automattic.tracks.android)
246251
implementation(libs.automattic.tracks.crashlogging)
@@ -426,9 +431,9 @@ dependencies {
426431

427432
implementation(libs.google.protobuf.javalite)
428433

429-
lintChecks(libs.android.security.lint)
430-
431434
testImplementation(testFixtures(project(":libs:fluxc-plugin")))
435+
436+
androidTestUtil libs.androidx.test.orchestrator
432437
}
433438

434439
protobuf {

0 commit comments

Comments
 (0)