From 604b7a715c73499f4affb4fe68551702ca955f54 Mon Sep 17 00:00:00 2001 From: Prince Mathew Date: Mon, 6 Jan 2025 01:06:40 +0530 Subject: [PATCH 1/4] Updated the android gradle version --- .gitignore | 4 +++- auth0_flutter/android/build.gradle | 6 +++--- auth0_flutter/android/gradle.properties | 1 + .../android/gradle/wrapper/gradle-wrapper.properties | 2 +- auth0_flutter/example/android/app/build.gradle | 4 ++-- .../android/gradle/wrapper/gradle-wrapper.properties | 4 ++-- auth0_flutter/example/ios/Runner/AppDelegate.swift | 2 +- auth0_flutter/ios/auth0_flutter.podspec | 2 +- 8 files changed, 14 insertions(+), 11 deletions(-) create mode 100644 auth0_flutter/android/gradle.properties diff --git a/.gitignore b/.gitignore index 37359416..93c50f1c 100644 --- a/.gitignore +++ b/.gitignore @@ -4,4 +4,6 @@ # Global coverage coverage/ -appium-test/node_modules/* \ No newline at end of file +appium-test/node_modules/* + +.idea/* diff --git a/auth0_flutter/android/build.gradle b/auth0_flutter/android/build.gradle index ebc4c173..673da8a7 100644 --- a/auth0_flutter/android/build.gradle +++ b/auth0_flutter/android/build.gradle @@ -6,7 +6,7 @@ buildscript { } dependencies { - classpath 'com.android.tools.build:gradle:7.4.2' + classpath "com.android.tools.build:gradle:8.4.0" classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" } } @@ -31,7 +31,7 @@ rootProject.allprojects { } android { - compileSdkVersion 31 + compileSdkVersion 34 if (project.android.hasProperty("namespace")) { namespace libApplicationId } @@ -72,7 +72,7 @@ android { dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" //noinspection GradleDynamicVersion - implementation 'com.auth0.android:auth0:2.10.2' + implementation 'com.auth0.android:auth0:2.11.0' testImplementation 'junit:junit:4.13.2' testImplementation 'org.hamcrest:java-hamcrest:2.0.0.0' diff --git a/auth0_flutter/android/gradle.properties b/auth0_flutter/android/gradle.properties new file mode 100644 index 00000000..5bac8ac5 --- /dev/null +++ b/auth0_flutter/android/gradle.properties @@ -0,0 +1 @@ +android.useAndroidX=true diff --git a/auth0_flutter/android/gradle/wrapper/gradle-wrapper.properties b/auth0_flutter/android/gradle/wrapper/gradle-wrapper.properties index 774fae87..17655d0e 100644 --- a/auth0_flutter/android/gradle/wrapper/gradle-wrapper.properties +++ b/auth0_flutter/android/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.6-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/auth0_flutter/example/android/app/build.gradle b/auth0_flutter/example/android/app/build.gradle index 2a880f11..576521a1 100644 --- a/auth0_flutter/example/android/app/build.gradle +++ b/auth0_flutter/example/android/app/build.gradle @@ -28,7 +28,7 @@ apply plugin: 'org.jetbrains.kotlinx.kover' apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" android { - compileSdk 31 + compileSdk 34 if (project.android.hasProperty("namespace")) { namespace exampleAppApplicationId } @@ -50,7 +50,7 @@ android { // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). applicationId exampleAppApplicationId minSdkVersion 21 - targetSdkVersion 31 + targetSdkVersion 34 versionCode flutterVersionCode.toInteger() versionName flutterVersionName testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" diff --git a/auth0_flutter/example/android/gradle/wrapper/gradle-wrapper.properties b/auth0_flutter/example/android/gradle/wrapper/gradle-wrapper.properties index 78a9a917..052e0719 100644 --- a/auth0_flutter/example/android/gradle/wrapper/gradle-wrapper.properties +++ b/auth0_flutter/example/android/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Fri Jun 23 08:50:38 CEST 2017 +#Fri Jan 03 12:46:32 IST 2025 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-8.6-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.1-bin.zip diff --git a/auth0_flutter/example/ios/Runner/AppDelegate.swift b/auth0_flutter/example/ios/Runner/AppDelegate.swift index bc5a0ec1..a2cc7ff3 100644 --- a/auth0_flutter/example/ios/Runner/AppDelegate.swift +++ b/auth0_flutter/example/ios/Runner/AppDelegate.swift @@ -2,7 +2,7 @@ import UIKit import Flutter import Auth0 -@UIApplicationMain +@main @objc class AppDelegate: FlutterAppDelegate { override func application( _ application: UIApplication, diff --git a/auth0_flutter/ios/auth0_flutter.podspec b/auth0_flutter/ios/auth0_flutter.podspec index 4318647d..2b043308 100644 --- a/auth0_flutter/ios/auth0_flutter.podspec +++ b/auth0_flutter/ios/auth0_flutter.podspec @@ -19,7 +19,7 @@ Pod::Spec.new do |s| s.osx.deployment_target = '11.0' s.osx.dependency 'FlutterMacOS' - s.dependency 'Auth0', '2.7.2' + s.dependency 'Auth0', '2.8.0' s.dependency 'JWTDecode', '3.1.0' s.dependency 'SimpleKeychain', '1.1.0' From 3e1abfe3e8028d6ab32d7ef84d0f4ae77d77115f Mon Sep 17 00:00:00 2001 From: Prince Mathew Date: Thu, 9 Jan 2025 14:31:14 +0530 Subject: [PATCH 2/4] Fixed a failing UT in the platform_interface file --- auth0_flutter_platform_interface/test/credentials_test.dart | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/auth0_flutter_platform_interface/test/credentials_test.dart b/auth0_flutter_platform_interface/test/credentials_test.dart index c9a63930..84ec42f0 100644 --- a/auth0_flutter_platform_interface/test/credentials_test.dart +++ b/auth0_flutter_platform_interface/test/credentials_test.dart @@ -72,8 +72,8 @@ void main() { scopes: {'a'}, user: const UserProfile(sub: '123', name: 'John Doe'), tokenType: 'Bearer'); - - expect(credentials.toMap()['expiresAt'], '2023-11-01T22:16:35.760Z'); + + expect(credentials.toMap()['expiresAt'], '2023-11-01T16:46:35.760Z'); }); }); } From 331490fb8a55fc82dbadca918314d77119ce3b70 Mon Sep 17 00:00:00 2001 From: Prince Mathew Date: Thu, 9 Jan 2025 14:45:24 +0530 Subject: [PATCH 3/4] Revert "Fixed a failing UT in the platform_interface file" This reverts commit 3e1abfe3e8028d6ab32d7ef84d0f4ae77d77115f. --- auth0_flutter_platform_interface/test/credentials_test.dart | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/auth0_flutter_platform_interface/test/credentials_test.dart b/auth0_flutter_platform_interface/test/credentials_test.dart index 84ec42f0..c9a63930 100644 --- a/auth0_flutter_platform_interface/test/credentials_test.dart +++ b/auth0_flutter_platform_interface/test/credentials_test.dart @@ -72,8 +72,8 @@ void main() { scopes: {'a'}, user: const UserProfile(sub: '123', name: 'John Doe'), tokenType: 'Bearer'); - - expect(credentials.toMap()['expiresAt'], '2023-11-01T16:46:35.760Z'); + + expect(credentials.toMap()['expiresAt'], '2023-11-01T22:16:35.760Z'); }); }); } From c44ebaf0deeee9f1809dae66916fbcf9b95303b5 Mon Sep 17 00:00:00 2001 From: Prince Mathew Date: Fri, 31 Jan 2025 14:32:33 +0530 Subject: [PATCH 4/4] Minor updated on the example gradle file --- auth0_flutter/example/android/app/build.gradle | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/auth0_flutter/example/android/app/build.gradle b/auth0_flutter/example/android/app/build.gradle index 6010d745..b9106048 100644 --- a/auth0_flutter/example/android/app/build.gradle +++ b/auth0_flutter/example/android/app/build.gradle @@ -54,8 +54,8 @@ android { versionCode flutterVersionCode.toInteger() versionName flutterVersionName testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" - manifestPlaceholders += [auth0Domain: "$System.env.AUTH0_DOMAIN", - auth0Scheme: "$System.env.AUTH0_CUSTOM_SCHEME"] + manifestPlaceholders += [auth0Domain: "YOUR_DOMAIN", + auth0Scheme: "YOUR_SCHEME"] testOptions { unitTests.returnDefaultValues = true