Skip to content

Commit

Permalink
Merge branch 'release/5.4.3'
Browse files Browse the repository at this point in the history
  • Loading branch information
matus-tomlein committed Aug 31, 2023
2 parents df8a726 + 4b5b2db commit 78dca5a
Show file tree
Hide file tree
Showing 10 changed files with 49 additions and 23 deletions.
10 changes: 10 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
Version 5.4.3 (2023-08-25)
--------------------------
Fix network type is tracked instead of network technology when filtering mobile context parameters (#635)
Upgrade com.google.android.gms:play-services-analytics from 18.0.2 to 18.0.3
Upgrade com.android.tools:desugar_jdk_libs from 1.1.5 to 1.1.9
Upgrade androidx.preference:preference from 1.2.0 to 1.2.1
Upgrade androidx.core:core-ktx from 1.9.0 to 1.10.1
Upgrade demo app dependencies
Set signing config for demo apps

Version 5.4.2 (2023-08-08)
--------------------------
Update vendor and version of the player schema used in media tracking (#632)
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.4.2
5.4.3
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ plugins {

subprojects {
group = 'com.snowplowanalytics'
version = '5.4.2'
version = '5.4.3'
repositories {
google()
maven {
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ systemProp.org.gradle.internal.http.socketTimeout=120000
SONATYPE_STAGING_PROFILE=comsnowplowanalytics
GROUP=com.snowplowanalytics
POM_ARTIFACT_ID=snowplow-android-tracker
VERSION_NAME=5.4.2
VERSION_NAME=5.4.3

POM_NAME=snowplow-android-tracker
POM_PACKAGING=aar
Expand Down
17 changes: 9 additions & 8 deletions snowplow-demo-compose/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ android {
versionName '1.0'

testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
signingConfig signingConfigs.debug
}

buildTypes {
Expand Down Expand Up @@ -48,14 +49,14 @@ dependencies {
implementation 'androidx.compose.material:material'
implementation 'androidx.compose.ui:ui-tooling-preview'
debugImplementation 'androidx.compose.ui:ui-tooling'
implementation 'androidx.activity:activity-compose:1.5.1'
implementation 'androidx.lifecycle:lifecycle-viewmodel-compose:2.5.1'
implementation "androidx.navigation:navigation-compose:2.5.3"
implementation 'androidx.core:core-ktx:1.7.0'
implementation 'androidx.appcompat:appcompat:1.5.1'
implementation 'com.google.android.material:material:1.6.0'
implementation 'androidx.preference:preference:1.1.1'
implementation 'androidx.browser:browser:1.3.0'
implementation 'androidx.activity:activity-compose:1.7.2'
implementation 'androidx.lifecycle:lifecycle-viewmodel-compose:2.6.1'
implementation "androidx.navigation:navigation-compose:2.6.0"
implementation 'androidx.core:core-ktx:1.10.1'
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'com.google.android.material:material:1.9.0'
implementation 'androidx.preference:preference:1.2.1'
implementation 'androidx.browser:browser:1.5.0'

implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation project(':snowplow-android-tracker')
Expand Down
3 changes: 2 additions & 1 deletion snowplow-demo-java/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ android {
targetSdkVersion 31
versionCode 3
versionName "0.3.0"
signingConfig signingConfigs.debug
}

buildTypes {
Expand Down Expand Up @@ -52,5 +53,5 @@ dependencies {
implementation 'com.squareup.okhttp3:okhttp:4.10.0'
implementation 'com.google.code.gson:gson:2.9.0'

coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.5'
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.9'
}
7 changes: 4 additions & 3 deletions snowplow-demo-kotlin/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ android {
versionName '1.0'

testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
signingConfig signingConfigs.debug
}

buildTypes {
Expand All @@ -33,12 +34,12 @@ android {
}

dependencies {
implementation 'androidx.core:core-ktx:1.9.0'
implementation 'androidx.core:core-ktx:1.10.1'
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'com.google.android.material:material:1.8.0'
implementation 'com.google.android.material:material:1.9.0'
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation project(':snowplow-android-tracker')
implementation 'androidx.preference:preference:1.2.0'
implementation 'androidx.preference:preference:1.2.1'
implementation 'androidx.browser:browser:1.5.0'
implementation 'com.google.android.gms:play-services-appset:16.0.2'
implementation "com.android.installreferrer:installreferrer:2.2"
Expand Down
8 changes: 4 additions & 4 deletions snowplow-tracker/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,12 @@ android {
dependencies {
implementation 'androidx.annotation:annotation:1.6.0'
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'androidx.core:core-ktx:1.9.0'
implementation 'androidx.preference:preference:1.2.0'
implementation 'androidx.core:core-ktx:1.10.1'
implementation 'androidx.preference:preference:1.2.1'
compileOnly "androidx.lifecycle:lifecycle-extensions:$project.archLifecycleVersion"
compileOnly "com.android.installreferrer:installreferrer:2.2"

coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.5'
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.9'

implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.squareup.okhttp3:okhttp:4.10.0'
Expand All @@ -102,7 +102,7 @@ dependencies {
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
androidTestImplementation 'com.google.android.gms:play-services-analytics:18.0.2'
androidTestImplementation 'com.google.android.gms:play-services-analytics:18.0.3'
androidTestImplementation 'com.squareup.okhttp3:mockwebserver:4.7.2'
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,19 @@ class PlatformContextTest {
Locale.setDefault(defaultLocale)
}

@Test
fun doesntSetTheNetworkTechIfNotRequested() {
val platformContext = PlatformContext(listOf(
PlatformContextProperty.NETWORK_TYPE
), context)
val sdj = platformContext.getMobileContext(false)
Assert.assertNotNull(sdj)
val sdjData = sdj!!.map["data"] as Map<*, *>

Assert.assertTrue(sdjData.containsKey(Parameters.NETWORK_TYPE))
Assert.assertFalse(sdjData.containsKey(Parameters.NETWORK_TECHNOLOGY))
}

// --- PRIVATE
private val context: Context
get() = InstrumentationRegistry.getInstrumentation().targetContext
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,15 +186,15 @@ class PlatformContext(
val networkInfo = deviceInfoMonitor.getNetworkInfo(context)
if (trackType) {
addToMap(
Parameters.NETWORK_TECHNOLOGY,
deviceInfoMonitor.getNetworkTechnology(networkInfo),
Parameters.NETWORK_TYPE,
deviceInfoMonitor.getNetworkType(networkInfo),
pairs
)
}
if (trackTech) {
addToMap(
Parameters.NETWORK_TYPE,
deviceInfoMonitor.getNetworkType(networkInfo),
Parameters.NETWORK_TECHNOLOGY,
deviceInfoMonitor.getNetworkTechnology(networkInfo),
pairs
)
}
Expand Down

0 comments on commit 78dca5a

Please sign in to comment.