Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .idea/.name

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 13 additions & 0 deletions .idea/deviceManager.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

90 changes: 44 additions & 46 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ plugins {
def buildBranch = project.hasProperty("buildBranch") ? project.getProperty("buildBranch") : "main"
def apiUrl = buildBranch == "main" ?
"https://devcuriousreader.wpcomstaging.com/container_app_manifest/prod/" :
"https://devcuriousreader.wpcomstaging.com/container_app_manifest/testing_branch/"
"https://devcuriousreader.wpcomstaging.com/container_app_manifest/prod/"
task printApiUrl {
doLast {
println(apiUrl)
Expand All @@ -19,12 +19,6 @@ task printApiUrl {
android {
namespace 'org.curiouslearning.container'
compileSdk 35
packagingOptions {
pickFirst "lib/x86/libc++_shared.so"
pickFirst "lib/x86_64/libc++_shared.so"
pickFirst "lib/armeabi-v7a/libc++_shared.so"
pickFirst "lib/arm64-v8a/libc++_shared.so"
}
defaultConfig {
applicationId "org.curiouslearning.container"
minSdk 24
Expand Down Expand Up @@ -62,8 +56,9 @@ android {

buildTypes {
debug{
testCoverageEnabled true
buildConfigField "String", "API_URL", "\"https://devcuriousreader.wpcomstaging.com/container_app_manifest/testing_branch/\""
buildConfigField "String", "API_URL", "\"https://devcuriousreader.wpcomstaging.com/container_app_manifest/prod/\""
enableUnitTestCoverage true
enableAndroidTestCoverage true
}
release {
signingConfig signingConfigs.release
Expand All @@ -79,62 +74,64 @@ android {
packagingOptions {
jniLibs {
useLegacyPackaging true
pickFirsts += ['lib/x86/libc++_shared.so', 'lib/x86_64/libc++_shared.so', 'lib/armeabi-v7a/libc++_shared.so', 'lib/arm64-v8a/libc++_shared.so']
}
}
}

dependencies {

//retrofit
implementation 'com.squareup.retrofit2:retrofit:2.9.0'
implementation 'com.squareup.retrofit2:converter-gson:2.9.0'
// Retrofit
implementation 'com.squareup.retrofit2:retrofit:2.11.0'
implementation 'com.squareup.retrofit2:converter-gson:2.11.0'

implementation platform("org.jetbrains.kotlin:kotlin-bom:1.9.24")

implementation platform("org.jetbrains.kotlin:kotlin-bom:1.8.22")
//RoomDatabase
implementation "androidx.room:room-runtime:2.3.0"
annotationProcessor "androidx.room:room-compiler:2.3.0"
// Room Database
implementation "androidx.room:room-runtime:2.6.1"
annotationProcessor "androidx.room:room-compiler:2.6.1"

//lifecycle-Viewmodal
implementation "androidx.lifecycle:lifecycle-viewmodel:2.5.1"
// Lifecycle / ViewModel
implementation "androidx.lifecycle:lifecycle-viewmodel:2.8.7"
implementation "androidx.lifecycle:lifecycle-livedata:2.8.7"

//firebase
implementation platform('com.google.firebase:firebase-bom:31.2.3')
// Firebase (firebase-core is deprecated — analytics covers everything)
implementation platform('com.google.firebase:firebase-bom:33.1.0')
implementation 'com.google.firebase:firebase-firestore'
implementation 'com.google.firebase:firebase-analytics'
implementation 'com.google.firebase:firebase-crashlytics:18.6.1'
implementation 'com.google.firebase:firebase-core:17.5.0'
implementation 'com.google.firebase:firebase-crashlytics'

//picasso (image caching)
// Picasso (image caching)
implementation 'com.squareup.picasso:picasso:2.71828'

//install refferal
// Install referrer
implementation "com.android.installreferrer:installreferrer:2.2"

implementation 'androidx.appcompat:appcompat:1.5.1'
implementation 'com.google.android.material:material:1.7.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'androidx.appcompat:appcompat:1.7.1'
implementation 'com.google.android.material:material:1.12.0'
implementation 'androidx.constraintlayout:constraintlayout:2.2.1'
implementation(platform("io.sentry:sentry-bom:7.17.0"))
implementation("io.sentry:sentry-android") {
exclude group: "io.sentry", module: "sentry-android-ndk"
}
// Source: https://mvnrepository.com/artifact/app.rive/rive-android
// Rive animations
implementation 'app.rive:rive-android:10.4.4'
// For initialization, you may want to add a dependency on Jetpack Startup
implementation "androidx.startup:startup-runtime:1.1.1"
testImplementation 'junit:junit:4.13.2'
testImplementation 'org.robolectric:robolectric:4.10.3'
testImplementation 'org.mockito:mockito-core:4.11.0'
testImplementation 'org.mockito:mockito-inline:4.11.0'
testImplementation 'androidx.test:core:1.5.0'

implementation "androidx.startup:startup-runtime:1.2.0"

androidTestImplementation 'androidx.test:core:1.5.0'
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation 'androidx.test:runner:1.5.2'
androidTestImplementation 'androidx.test:rules:1.5.0'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
androidTestImplementation 'androidx.test.espresso:espresso-contrib:3.5.1'
androidTestImplementation 'org.mockito:mockito-android:4.11.0'
// Test dependencies
testImplementation 'junit:junit:4.13.2'
testImplementation 'org.robolectric:robolectric:4.13'
testImplementation 'org.mockito:mockito-core:5.12.0'
testImplementation 'org.mockito:mockito-inline:5.2.0'
testImplementation 'androidx.test:core:1.6.1'

androidTestImplementation 'androidx.test:core:1.6.1'
androidTestImplementation 'androidx.test.ext:junit:1.2.1'
androidTestImplementation 'androidx.test:runner:1.6.2'
androidTestImplementation 'androidx.test:rules:1.6.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.6.1'
androidTestImplementation 'androidx.test.espresso:espresso-contrib:3.6.1'
androidTestImplementation 'org.mockito:mockito-android:5.12.0'

implementation 'com.facebook.android:facebook-android-sdk:17.0.0'
}
Expand All @@ -146,7 +143,8 @@ def coverageSourceDirs = [
"src/main/java"
]

task jacocoTestReport(type: JacocoReport, dependsOn: ['testDebugUnitTest']) {
tasks.register("jacocoTestReport", JacocoReport) {
dependsOn('testDebugUnitTest')
group = "Reporting"
description = "Generate Jacoco coverage reports after running tests."

Expand All @@ -156,7 +154,7 @@ task jacocoTestReport(type: JacocoReport, dependsOn: ['testDebugUnitTest']) {
}

classDirectories.setFrom(fileTree(
dir: "$buildDir/intermediates/classes/debug",
dir: layout.buildDirectory.dir("intermediates/classes/debug"),
excludes: [
'**/R.class',
'**/R$*.class',
Expand All @@ -172,7 +170,7 @@ task jacocoTestReport(type: JacocoReport, dependsOn: ['testDebugUnitTest']) {
))

sourceDirectories.setFrom(files(coverageSourceDirs))
executionData.setFrom(fileTree(dir: "$buildDir", includes: [
executionData.setFrom(fileTree(dir: layout.buildDirectory, includes: [
"jacoco/testDebugUnitTest.exec",
"outputs/code-coverage/connected/*coverage.ec"
]))
Expand Down
7 changes: 3 additions & 4 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
<application
android:name=".MyApplication"
android:allowBackup="true"
android:extractNativeLibs="true"
android:screenOrientation="portrait"
android:dataExtractionRules="@xml/data_extraction_rules"
android:fullBackupContent="@xml/backup_rules"
Expand Down Expand Up @@ -39,7 +38,7 @@
<meta-data android:name="com.facebook.sdk.AdvertiserIDCollectionEnabled"
android:value="false" />
<activity
android:name=".WebApp"
android:name=".presentation.webapp.WebAppActivity"
android:screenOrientation="portrait"
android:exported="false">
<meta-data
Expand Down Expand Up @@ -102,7 +101,7 @@
<!-- Required: set your sentry.io project identifier (DSN) -->
<meta-data android:name="io.sentry.dsn" android:value="https://3e3bfa9bd4473edd4e0b0d502195f4de@o4504951275651072.ingest.us.sentry.io/4510001311383552" />
<!-- Add data like request headers, user ip address and device name, see https://docs.sentry.io/platforms/android/data-management/data-collected/ for more info -->
<meta-data android:name="io.sentry.send-default-pii" android:value="true" />
<meta-data android:name="io.sentry.send-default-pii" android:value="false" />

<!-- enable automatic breadcrumbs for user interactions (clicks, swipes, scrolls) -->
<meta-data android:name="io.sentry.traces.user-interaction.enable" android:value="true" />
Expand All @@ -112,7 +111,7 @@
<meta-data android:name="io.sentry.attach-view-hierarchy" android:value="true" />

<!-- enable the performance API by setting a sample-rate, adjust in production env -->
<meta-data android:name="io.sentry.traces.sample-rate" android:value="1.0" />
<meta-data android:name="io.sentry.traces.sample-rate" android:value="0.1" />
</application>


Expand Down
Loading