File tree Expand file tree Collapse file tree 10 files changed +260
-158
lines changed
src/androidTest/java/com/talkable/demo Expand file tree Collapse file tree 10 files changed +260
-158
lines changed Original file line number Diff line number Diff line change 1
1
apply plugin : ' com.android.application'
2
2
3
-
4
3
def keystoreProperties = new Properties ()
5
4
keystoreProperties. load(new FileInputStream (rootProject. file(" keystore.properties" )))
6
5
7
6
android {
7
+ namespace ' com.talkable.demo'
8
8
signingConfigs {
9
9
config {
10
10
keyAlias keystoreProperties[' keyAlias' ]
@@ -13,11 +13,11 @@ android {
13
13
storePassword keystoreProperties[' storePassword' ]
14
14
}
15
15
}
16
- compileSdkVersion 31
16
+ compileSdkVersion 34
17
17
defaultConfig {
18
18
applicationId " com.talkable.demo"
19
- minSdkVersion 16
20
- targetSdkVersion 31
19
+ minSdkVersion 19
20
+ targetSdkVersion 34
21
21
versionCode 34
22
22
versionName " 0.5.3"
23
23
}
@@ -32,12 +32,13 @@ android {
32
32
sourceCompatibility JavaVersion . VERSION_1_8
33
33
targetCompatibility JavaVersion . VERSION_1_8
34
34
}
35
+ buildToolsVersion ' 36.0.0'
35
36
}
36
37
37
38
dependencies {
38
39
implementation fileTree(include : [' *.jar' ], dir : ' libs' )
39
40
implementation project(path : ' :sdk' )
40
41
implementation ' com.google.android.material:material:1.0.0'
41
- implementation ' androidx.legacy:legacy-support-v4 :1.0.0 '
42
- testImplementation ' junit:junit:4.12 '
42
+ androidTestImplementation ' androidx.test.ext:junit :1.2.1 '
43
+ androidTestImplementation ' androidx.test.espresso:espresso-core:3.6.1 '
43
44
}
Original file line number Diff line number Diff line change 1
1
package com .talkable .demo ;
2
2
3
3
import android .app .Application ;
4
- import android .test .ApplicationTestCase ;
4
+ import androidx .test .core .app .ApplicationProvider ;
5
+ import org .junit .Test ;
6
+ import static org .junit .Assert .*;
5
7
6
8
/**
7
- * <a href="http ://d .android.com/tools/testing/testing_android.html ">Testing Fundamentals</a>
9
+ * <a href="https ://developer .android.com/studio/test ">Testing Fundamentals</a>
8
10
*/
9
- public class ApplicationTest extends ApplicationTestCase <Application > {
10
- public ApplicationTest () {
11
- super (Application .class );
11
+
12
+ public class ApplicationTest {
13
+ @ Test
14
+ public void testApplication () {
15
+ // Getting the application context using AndroidX ApplicationProvider
16
+ Application app = ApplicationProvider .getApplicationContext ();
17
+ assertNotNull (app ); // Assert that the Application context is not null
12
18
}
13
19
}
Original file line number Diff line number Diff line change 1
1
// Top-level build file where you can add configuration options common to all sub-projects/modules.
2
2
3
3
buildscript {
4
+ // Required for sdk version retrieval to work as of Android Studio 4.1.0: https://issuetracker.google.com/issues/158695880
5
+ project. ext. set(" sdk_version_code" , 42 )
6
+ project. ext. set(" sdk_version_name" , " 0.5.13" )
7
+
4
8
repositories {
5
9
mavenCentral()
6
10
google()
7
11
}
8
12
dependencies {
9
- classpath ' com.android.tools.build:gradle:3.6 .4'
13
+ classpath ' com.android.tools.build:gradle:8.1 .4'
10
14
classpath ' com.github.bjoernq:unmockplugin:0.7.6'
11
- classpath ' com.github.dcendents:android-maven-gradle-plugin:2.0 '
15
+ classpath ' com.github.dcendents:android-maven-gradle-plugin:2.1 '
12
16
13
17
// NOTE: Do not place your application dependencies here; they belong
14
18
// in the individual module build.gradle files
Original file line number Diff line number Diff line change 16
16
# This option should only be used with decoupled projects. More details, visit
17
17
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
18
18
# org.gradle.parallel=true
19
+ android.defaults.buildfeatures.buildconfig =true
19
20
android.enableJetifier =true
21
+ android.nonFinalResIds =false
22
+ android.nonTransitiveRClass =false
20
23
android.useAndroidX =true
Original file line number Diff line number Diff line change 1
- # Wed Jun 19 22:47:32 EEST 2019
2
1
distributionBase =GRADLE_USER_HOME
3
2
distributionPath =wrapper/dists
3
+ distributionUrl =https\://services.gradle.org/distributions/gradle-8.5-bin.zip
4
+ networkTimeout =10000
5
+ validateDistributionUrl =true
4
6
zipStoreBase =GRADLE_USER_HOME
5
7
zipStorePath =wrapper/dists
6
- distributionUrl =https\://services.gradle.org/distributions/gradle-6.3-all.zip
You can’t perform that action at this time.
0 commit comments