diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml
index f04c014..468d894 100644
--- a/.github/workflows/build_and_test.yml
+++ b/.github/workflows/build_and_test.yml
@@ -1,9 +1,15 @@
name: Flutter Build And Test
on:
push:
+ ## all branches
branches:
- main
- - unittest
+ - dev
+ - feature/*
+ - bugfix/*
+ - hotfix/*
+ - release/v*
+
pull_request:
branches:
- main
@@ -23,13 +29,22 @@ jobs:
uses: dart-lang/setup-dart@v1.6.5
with:
dart-version: 3.5.4
+ - name: Setup Java JDK 17
+ uses: actions/setup-java@v4
+ with:
+ distribution: 'temurin'
+ java-version: '17'
+ - name: set JAVA_HOME
+ run: echo "JAVA_HOME=/usr/lib/jvm/temurin-17-jdk-amd64" >> $GITHUB_ENV
+ - name: flutter jdk configuration
+ run: flutter config --jdk-dir /usr/lib/jvm/temurin-17-jdk-amd64
- name: Install dependencies
run: flutter pub get
- name: Analyze
run: flutter analyze
- name: Run tests
run: flutter test
-# - name: Build APK
-# run: flutter build apk --release --target lib/main/main_prod.dart
-# - name: Build Android App Bundle
-# run: flutter build appbundle --release --target lib/main/main_prod.dart
+ - name: Build APK
+ run: flutter build apk --release --target lib/main/main_prod.dart
+ - name: Build Android App Bundle
+ run: flutter build appbundle --release --target lib/main/main_prod.dart
diff --git a/.metadata b/.metadata
index b41277d..c2aa44b 100644
--- a/.metadata
+++ b/.metadata
@@ -4,7 +4,7 @@
# This file should be version controlled and should not be manually edited.
version:
- revision: "367f9ea16bfae1ca451b9cc27c1366870b187ae2"
+ revision: "603104015dd692ea3403755b55d07813d5cf8965"
channel: "stable"
project_type: app
@@ -13,26 +13,26 @@ project_type: app
migration:
platforms:
- platform: root
- create_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
- base_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
+ create_revision: 603104015dd692ea3403755b55d07813d5cf8965
+ base_revision: 603104015dd692ea3403755b55d07813d5cf8965
- platform: android
- create_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
- base_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
+ create_revision: 603104015dd692ea3403755b55d07813d5cf8965
+ base_revision: 603104015dd692ea3403755b55d07813d5cf8965
- platform: ios
- create_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
- base_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
+ create_revision: 603104015dd692ea3403755b55d07813d5cf8965
+ base_revision: 603104015dd692ea3403755b55d07813d5cf8965
- platform: linux
- create_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
- base_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
+ create_revision: 603104015dd692ea3403755b55d07813d5cf8965
+ base_revision: 603104015dd692ea3403755b55d07813d5cf8965
- platform: macos
- create_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
- base_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
+ create_revision: 603104015dd692ea3403755b55d07813d5cf8965
+ base_revision: 603104015dd692ea3403755b55d07813d5cf8965
- platform: web
- create_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
- base_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
+ create_revision: 603104015dd692ea3403755b55d07813d5cf8965
+ base_revision: 603104015dd692ea3403755b55d07813d5cf8965
- platform: windows
- create_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
- base_revision: 367f9ea16bfae1ca451b9cc27c1366870b187ae2
+ create_revision: 603104015dd692ea3403755b55d07813d5cf8965
+ base_revision: 603104015dd692ea3403755b55d07813d5cf8965
# User provided section
diff --git a/android/.gitignore b/android/.gitignore
index 6f56801..55afd91 100644
--- a/android/.gitignore
+++ b/android/.gitignore
@@ -7,7 +7,7 @@ gradle-wrapper.jar
GeneratedPluginRegistrant.java
# Remember to never publicly share your keystore.
-# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
+# See https://flutter.dev/to/reference-keystore
key.properties
**/*.keystore
**/*.jks
diff --git a/android/app/build.gradle b/android/app/build.gradle
index 8b42842..06e24b6 100644
--- a/android/app/build.gradle
+++ b/android/app/build.gradle
@@ -1,67 +1,44 @@
plugins {
id "com.android.application"
id "kotlin-android"
+ // The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
id "dev.flutter.flutter-gradle-plugin"
}
-def localProperties = new Properties()
-def localPropertiesFile = rootProject.file('local.properties')
-if (localPropertiesFile.exists()) {
- localPropertiesFile.withReader('UTF-8') { reader ->
- localProperties.load(reader)
- }
-}
-
-def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
-if (flutterVersionCode == null) {
- flutterVersionCode = '1'
-}
-
-def flutterVersionName = localProperties.getProperty('flutter.versionName')
-if (flutterVersionName == null) {
- flutterVersionName = '1.0'
-}
-
android {
namespace = "com.cevheri.flutter.flutter_bloc_advance"
- compileSdkVersion = flutter.compileSdkVersion
+ compileSdk = flutter.compileSdkVersion
ndkVersion = flutter.ndkVersion
compileOptions {
- sourceCompatibility JavaVersion.VERSION_1_8
- targetCompatibility JavaVersion.VERSION_1_8
+ sourceCompatibility = JavaVersion.VERSION_1_8
+ targetCompatibility = JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = JavaVersion.VERSION_1_8
}
- sourceSets {
- main.java.srcDirs += 'src/main/kotlin'
- }
-
defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
- applicationId "com.cevheri.flutter.flutter_bloc_advance"
+ applicationId = "com.cevheri.flutter.flutter_bloc_advance"
// You can update the following values to match your application needs.
- // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
- minSdkVersion 30
- targetSdkVersion flutter.targetSdkVersion
- versionCode flutterVersionCode.toInteger()
- versionName flutterVersionName
+ // For more information, see: https://flutter.dev/to/review-gradle-config.
+ minSdk = flutter.minSdkVersion
+ targetSdk = flutter.targetSdkVersion
+ versionCode = flutter.versionCode
+ versionName = flutter.versionName
}
buildTypes {
release {
// TODO: Add your own signing config for the release build.
// Signing with the debug keys for now, so `flutter run --release` works.
- signingConfig signingConfigs.debug
+ signingConfig = signingConfigs.debug
}
}
}
flutter {
- source '../..'
+ source = "../.."
}
-
-dependencies {}
diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml
index 1313acf..20daa34 100644
--- a/android/app/src/main/AndroidManifest.xml
+++ b/android/app/src/main/AndroidManifest.xml
@@ -7,6 +7,7 @@
android:name=".MainActivity"
android:exported="true"
android:launchMode="singleTop"
+ android:taskAffinity=""
android:theme="@style/LaunchTheme"
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
android:hardwareAccelerated="true"
@@ -30,4 +31,15 @@
android:name="flutterEmbedding"
android:value="2" />
+
+
+
+
+
+
+
diff --git a/android/app/src/main/kotlin/com/cevheri/flutter/flutter_bloc_advance/MainActivity.kt b/android/app/src/main/kotlin/com/cevheri/flutter/flutter_bloc_advance/MainActivity.kt
index 4c6fd10..d1fff9b 100644
--- a/android/app/src/main/kotlin/com/cevheri/flutter/flutter_bloc_advance/MainActivity.kt
+++ b/android/app/src/main/kotlin/com/cevheri/flutter/flutter_bloc_advance/MainActivity.kt
@@ -2,5 +2,4 @@ package com.cevheri.flutter.flutter_bloc_advance
import io.flutter.embedding.android.FlutterActivity
-class MainActivity: FlutterActivity() {
-}
+class MainActivity: FlutterActivity()
diff --git a/android/build.gradle b/android/build.gradle
index 20e69bd..d2ffbff 100644
--- a/android/build.gradle
+++ b/android/build.gradle
@@ -1,16 +1,3 @@
-buildscript {
- ext.kotlin_version = "1.8.22"
- repositories {
- google()
- mavenCentral()
- }
-
- dependencies {
- classpath 'com.android.tools.build:gradle:8.7.2'
- classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
- }
-}
-
allprojects {
repositories {
google()
@@ -18,12 +5,12 @@ allprojects {
}
}
-rootProject.buildDir = '../build'
+rootProject.buildDir = "../build"
subprojects {
project.buildDir = "${rootProject.buildDir}/${project.name}"
}
subprojects {
- project.evaluationDependsOn(':app')
+ project.evaluationDependsOn(":app")
}
tasks.register("clean", Delete) {
diff --git a/android/gradle.properties b/android/gradle.properties
index 94adc3a..2597170 100644
--- a/android/gradle.properties
+++ b/android/gradle.properties
@@ -1,3 +1,3 @@
-org.gradle.jvmargs=-Xmx1536M
+org.gradle.jvmargs=-Xmx4G -XX:MaxMetaspaceSize=2G -XX:+HeapDumpOnOutOfMemoryError
android.useAndroidX=true
android.enableJetifier=true
diff --git a/android/gradle/wrapper/gradle-wrapper.properties b/android/gradle/wrapper/gradle-wrapper.properties
index 348c409..7bb2df6 100644
--- a/android/gradle/wrapper/gradle-wrapper.properties
+++ b/android/gradle/wrapper/gradle-wrapper.properties
@@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-all.zip
+distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-all.zip
diff --git a/android/settings.gradle b/android/settings.gradle
index 55c4ca8..b9e43bd 100644
--- a/android/settings.gradle
+++ b/android/settings.gradle
@@ -5,16 +5,21 @@ pluginManagement {
def flutterSdkPath = properties.getProperty("flutter.sdk")
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
return flutterSdkPath
- }
- settings.ext.flutterSdkPath = flutterSdkPath()
+ }()
- includeBuild("${settings.ext.flutterSdkPath}/packages/flutter_tools/gradle")
+ includeBuild("$flutterSdkPath/packages/flutter_tools/gradle")
- plugins {
- id "dev.flutter.flutter-gradle-plugin" version "1.0.0" apply false
+ repositories {
+ google()
+ mavenCentral()
+ gradlePluginPortal()
}
}
-include ":app"
+plugins {
+ id "dev.flutter.flutter-plugin-loader" version "1.0.0"
+ id "com.android.application" version "8.1.0" apply false
+ id "org.jetbrains.kotlin.android" version "1.8.22" apply false
+}
-apply from: "${settings.ext.flutterSdkPath}/packages/flutter_tools/gradle/app_plugin_loader.gradle"
+include ":app"
diff --git a/ios/Flutter/Debug.xcconfig b/ios/Flutter/Debug.xcconfig
index ec97fc6..592ceee 100644
--- a/ios/Flutter/Debug.xcconfig
+++ b/ios/Flutter/Debug.xcconfig
@@ -1,2 +1 @@
-#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
#include "Generated.xcconfig"
diff --git a/ios/Flutter/Release.xcconfig b/ios/Flutter/Release.xcconfig
index c4855bf..592ceee 100644
--- a/ios/Flutter/Release.xcconfig
+++ b/ios/Flutter/Release.xcconfig
@@ -1,2 +1 @@
-#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
#include "Generated.xcconfig"
diff --git a/ios/Runner.xcodeproj/project.pbxproj b/ios/Runner.xcodeproj/project.pbxproj
index 99f989e..e85d081 100644
--- a/ios/Runner.xcodeproj/project.pbxproj
+++ b/ios/Runner.xcodeproj/project.pbxproj
@@ -8,14 +8,12 @@
/* Begin PBXBuildFile section */
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
- 1A822DCF3C2679B5C54C923A /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 78360699211AF3BDFB78F32A /* Pods_Runner.framework */; };
331C808B294A63AB00263BE5 /* RunnerTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 331C807B294A618700263BE5 /* RunnerTests.swift */; };
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
- DB291563DEC9E3C7333BAE65 /* Pods_RunnerTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A896DF385D717B1D70F3ACCF /* Pods_RunnerTests.framework */; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
@@ -42,19 +40,14 @@
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
- 03F4D3625B42CE5063AA75BE /* Pods-RunnerTests.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.profile.xcconfig"; path = "Target Support Files/Pods-RunnerTests/Pods-RunnerTests.profile.xcconfig"; sourceTree = ""; };
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; };
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; };
- 252F2EA4EFE6CBA75DEFD8FB /* Pods-RunnerTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.debug.xcconfig"; path = "Target Support Files/Pods-RunnerTests/Pods-RunnerTests.debug.xcconfig"; sourceTree = ""; };
331C807B294A618700263BE5 /* RunnerTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RunnerTests.swift; sourceTree = ""; };
331C8081294A63A400263BE5 /* RunnerTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = RunnerTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; };
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; };
74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; };
- 78360699211AF3BDFB78F32A /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; };
- 8BBA90213E40D7BC9F40DCAD /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = ""; };
- 9688600BD8A2FFD82877B7CC /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = ""; };
9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; };
9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; };
97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
@@ -62,9 +55,6 @@
97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; };
97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; };
97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
- A732D93D11A5D2ADAACFE963 /* Pods-RunnerTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.release.xcconfig"; path = "Target Support Files/Pods-RunnerTests/Pods-RunnerTests.release.xcconfig"; sourceTree = ""; };
- A896DF385D717B1D70F3ACCF /* Pods_RunnerTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_RunnerTests.framework; sourceTree = BUILT_PRODUCTS_DIR; };
- F5BDCCE043EFAB4BAE5C72A6 /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = ""; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@@ -72,35 +62,12 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
- 1A822DCF3C2679B5C54C923A /* Pods_Runner.framework in Frameworks */,
- );
- runOnlyForDeploymentPostprocessing = 0;
- };
- C5C70887F6C46847D8CC23B3 /* Frameworks */ = {
- isa = PBXFrameworksBuildPhase;
- buildActionMask = 2147483647;
- files = (
- DB291563DEC9E3C7333BAE65 /* Pods_RunnerTests.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
- 0293A6C2A774E1B1AD101078 /* Pods */ = {
- isa = PBXGroup;
- children = (
- 8BBA90213E40D7BC9F40DCAD /* Pods-Runner.debug.xcconfig */,
- 9688600BD8A2FFD82877B7CC /* Pods-Runner.release.xcconfig */,
- F5BDCCE043EFAB4BAE5C72A6 /* Pods-Runner.profile.xcconfig */,
- 252F2EA4EFE6CBA75DEFD8FB /* Pods-RunnerTests.debug.xcconfig */,
- A732D93D11A5D2ADAACFE963 /* Pods-RunnerTests.release.xcconfig */,
- 03F4D3625B42CE5063AA75BE /* Pods-RunnerTests.profile.xcconfig */,
- );
- name = Pods;
- path = Pods;
- sourceTree = "";
- };
331C8082294A63A400263BE5 /* RunnerTests */ = {
isa = PBXGroup;
children = (
@@ -109,15 +76,6 @@
path = RunnerTests;
sourceTree = "";
};
- 6CFBBC0234709C60BD391835 /* Frameworks */ = {
- isa = PBXGroup;
- children = (
- 78360699211AF3BDFB78F32A /* Pods_Runner.framework */,
- A896DF385D717B1D70F3ACCF /* Pods_RunnerTests.framework */,
- );
- name = Frameworks;
- sourceTree = "";
- };
9740EEB11CF90186004384FC /* Flutter */ = {
isa = PBXGroup;
children = (
@@ -136,8 +94,6 @@
97C146F01CF9000F007C117D /* Runner */,
97C146EF1CF9000F007C117D /* Products */,
331C8082294A63A400263BE5 /* RunnerTests */,
- 0293A6C2A774E1B1AD101078 /* Pods */,
- 6CFBBC0234709C60BD391835 /* Frameworks */,
);
sourceTree = "";
};
@@ -172,10 +128,8 @@
isa = PBXNativeTarget;
buildConfigurationList = 331C8087294A63A400263BE5 /* Build configuration list for PBXNativeTarget "RunnerTests" */;
buildPhases = (
- 36742BC706CF04B4CC176EFA /* [CP] Check Pods Manifest.lock */,
331C807D294A63A400263BE5 /* Sources */,
331C807F294A63A400263BE5 /* Resources */,
- C5C70887F6C46847D8CC23B3 /* Frameworks */,
);
buildRules = (
);
@@ -191,14 +145,12 @@
isa = PBXNativeTarget;
buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
buildPhases = (
- 6D329892747F70CC0258D629 /* [CP] Check Pods Manifest.lock */,
9740EEB61CF901F6004384FC /* Run Script */,
97C146EA1CF9000F007C117D /* Sources */,
97C146EB1CF9000F007C117D /* Frameworks */,
97C146EC1CF9000F007C117D /* Resources */,
9705A1C41CF9048500538489 /* Embed Frameworks */,
3B06AD1E1E4923F5004D2608 /* Thin Binary */,
- 7443BF9C0E76BA224DB06702 /* [CP] Embed Pods Frameworks */,
);
buildRules = (
);
@@ -270,28 +222,6 @@
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
- 36742BC706CF04B4CC176EFA /* [CP] Check Pods Manifest.lock */ = {
- isa = PBXShellScriptBuildPhase;
- buildActionMask = 2147483647;
- files = (
- );
- inputFileListPaths = (
- );
- inputPaths = (
- "${PODS_PODFILE_DIR_PATH}/Podfile.lock",
- "${PODS_ROOT}/Manifest.lock",
- );
- name = "[CP] Check Pods Manifest.lock";
- outputFileListPaths = (
- );
- outputPaths = (
- "$(DERIVED_FILE_DIR)/Pods-RunnerTests-checkManifestLockResult.txt",
- );
- runOnlyForDeploymentPostprocessing = 0;
- shellPath = /bin/sh;
- shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
- showEnvVarsInLog = 0;
- };
3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
isa = PBXShellScriptBuildPhase;
alwaysOutOfDate = 1;
@@ -308,45 +238,6 @@
shellPath = /bin/sh;
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
};
- 6D329892747F70CC0258D629 /* [CP] Check Pods Manifest.lock */ = {
- isa = PBXShellScriptBuildPhase;
- buildActionMask = 2147483647;
- files = (
- );
- inputFileListPaths = (
- );
- inputPaths = (
- "${PODS_PODFILE_DIR_PATH}/Podfile.lock",
- "${PODS_ROOT}/Manifest.lock",
- );
- name = "[CP] Check Pods Manifest.lock";
- outputFileListPaths = (
- );
- outputPaths = (
- "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt",
- );
- runOnlyForDeploymentPostprocessing = 0;
- shellPath = /bin/sh;
- shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
- showEnvVarsInLog = 0;
- };
- 7443BF9C0E76BA224DB06702 /* [CP] Embed Pods Frameworks */ = {
- isa = PBXShellScriptBuildPhase;
- buildActionMask = 2147483647;
- files = (
- );
- inputFileListPaths = (
- "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist",
- );
- name = "[CP] Embed Pods Frameworks";
- outputFileListPaths = (
- "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist",
- );
- runOnlyForDeploymentPostprocessing = 0;
- shellPath = /bin/sh;
- shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";
- showEnvVarsInLog = 0;
- };
9740EEB61CF901F6004384FC /* Run Script */ = {
isa = PBXShellScriptBuildPhase;
alwaysOutOfDate = 1;
@@ -416,6 +307,7 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
+ ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
@@ -445,6 +337,7 @@
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
+ ENABLE_USER_SCRIPT_SANDBOXING = NO;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
@@ -485,7 +378,6 @@
};
331C8088294A63A400263BE5 /* Debug */ = {
isa = XCBuildConfiguration;
- baseConfigurationReference = 252F2EA4EFE6CBA75DEFD8FB /* Pods-RunnerTests.debug.xcconfig */;
buildSettings = {
BUNDLE_LOADER = "$(TEST_HOST)";
CODE_SIGN_STYLE = Automatic;
@@ -503,7 +395,6 @@
};
331C8089294A63A400263BE5 /* Release */ = {
isa = XCBuildConfiguration;
- baseConfigurationReference = A732D93D11A5D2ADAACFE963 /* Pods-RunnerTests.release.xcconfig */;
buildSettings = {
BUNDLE_LOADER = "$(TEST_HOST)";
CODE_SIGN_STYLE = Automatic;
@@ -519,7 +410,6 @@
};
331C808A294A63A400263BE5 /* Profile */ = {
isa = XCBuildConfiguration;
- baseConfigurationReference = 03F4D3625B42CE5063AA75BE /* Pods-RunnerTests.profile.xcconfig */;
buildSettings = {
BUNDLE_LOADER = "$(TEST_HOST)";
CODE_SIGN_STYLE = Automatic;
@@ -537,6 +427,7 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
+ ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
@@ -566,6 +457,7 @@
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
+ ENABLE_USER_SCRIPT_SANDBOXING = NO;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
@@ -592,6 +484,7 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
+ ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
@@ -621,6 +514,7 @@
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
+ ENABLE_USER_SCRIPT_SANDBOXING = NO;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
diff --git a/ios/Runner.xcworkspace/contents.xcworkspacedata b/ios/Runner.xcworkspace/contents.xcworkspacedata
index 21a3cc1..1d526a1 100644
--- a/ios/Runner.xcworkspace/contents.xcworkspacedata
+++ b/ios/Runner.xcworkspace/contents.xcworkspacedata
@@ -4,7 +4,4 @@
-
-
diff --git a/ios/Runner/AppDelegate.swift b/ios/Runner/AppDelegate.swift
index b636303..6266644 100644
--- a/ios/Runner/AppDelegate.swift
+++ b/ios/Runner/AppDelegate.swift
@@ -1,5 +1,5 @@
-import UIKit
import Flutter
+import UIKit
@main
@objc class AppDelegate: FlutterAppDelegate {
diff --git a/linux/CMakeLists.txt b/linux/CMakeLists.txt
index 1733c6f..d3dd510 100644
--- a/linux/CMakeLists.txt
+++ b/linux/CMakeLists.txt
@@ -123,6 +123,12 @@ foreach(bundled_library ${PLUGIN_BUNDLED_LIBRARIES})
COMPONENT Runtime)
endforeach(bundled_library)
+# Copy the native assets provided by the build.dart from all packages.
+set(NATIVE_ASSETS_DIR "${PROJECT_BUILD_DIR}native_assets/linux/")
+install(DIRECTORY "${NATIVE_ASSETS_DIR}"
+ DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
+ COMPONENT Runtime)
+
# Fully re-copy the assets directory on each build to avoid having stale files
# from a previous install.
set(FLUTTER_ASSET_DIR_NAME "flutter_assets")
diff --git a/linux/my_application.cc b/linux/my_application.cc
index c4d3a07..5f27b33 100644
--- a/linux/my_application.cc
+++ b/linux/my_application.cc
@@ -81,6 +81,24 @@ static gboolean my_application_local_command_line(GApplication* application, gch
return TRUE;
}
+// Implements GApplication::startup.
+static void my_application_startup(GApplication* application) {
+ //MyApplication* self = MY_APPLICATION(object);
+
+ // Perform any actions required at application startup.
+
+ G_APPLICATION_CLASS(my_application_parent_class)->startup(application);
+}
+
+// Implements GApplication::shutdown.
+static void my_application_shutdown(GApplication* application) {
+ //MyApplication* self = MY_APPLICATION(object);
+
+ // Perform any actions required at application shutdown.
+
+ G_APPLICATION_CLASS(my_application_parent_class)->shutdown(application);
+}
+
// Implements GObject::dispose.
static void my_application_dispose(GObject* object) {
MyApplication* self = MY_APPLICATION(object);
@@ -91,6 +109,8 @@ static void my_application_dispose(GObject* object) {
static void my_application_class_init(MyApplicationClass* klass) {
G_APPLICATION_CLASS(klass)->activate = my_application_activate;
G_APPLICATION_CLASS(klass)->local_command_line = my_application_local_command_line;
+ G_APPLICATION_CLASS(klass)->startup = my_application_startup;
+ G_APPLICATION_CLASS(klass)->shutdown = my_application_shutdown;
G_OBJECT_CLASS(klass)->dispose = my_application_dispose;
}
diff --git a/macos/Flutter/Flutter-Debug.xcconfig b/macos/Flutter/Flutter-Debug.xcconfig
index 4b81f9b..c2efd0b 100644
--- a/macos/Flutter/Flutter-Debug.xcconfig
+++ b/macos/Flutter/Flutter-Debug.xcconfig
@@ -1,2 +1 @@
-#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
#include "ephemeral/Flutter-Generated.xcconfig"
diff --git a/macos/Flutter/Flutter-Release.xcconfig b/macos/Flutter/Flutter-Release.xcconfig
index 5caa9d1..c2efd0b 100644
--- a/macos/Flutter/Flutter-Release.xcconfig
+++ b/macos/Flutter/Flutter-Release.xcconfig
@@ -1,2 +1 @@
-#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
#include "ephemeral/Flutter-Generated.xcconfig"
diff --git a/macos/Runner.xcodeproj/project.pbxproj b/macos/Runner.xcodeproj/project.pbxproj
index f8e19af..fbd6979 100644
--- a/macos/Runner.xcodeproj/project.pbxproj
+++ b/macos/Runner.xcodeproj/project.pbxproj
@@ -226,8 +226,9 @@
33CC10E52044A3C60003C045 /* Project object */ = {
isa = PBXProject;
attributes = {
+ BuildIndependentTargetsInParallel = YES;
LastSwiftUpdateCheck = 0920;
- LastUpgradeCheck = 1430;
+ LastUpgradeCheck = 1510;
ORGANIZATIONNAME = "";
TargetAttributes = {
331C80D4294CF70F00263BE5 = {
@@ -424,6 +425,7 @@
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
+ ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
@@ -447,9 +449,11 @@
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CODE_SIGN_IDENTITY = "-";
COPY_PHASE_STRIP = NO;
+ DEAD_CODE_STRIPPING = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
+ ENABLE_USER_SCRIPT_SANDBOXING = NO;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
@@ -497,6 +501,7 @@
baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
+ ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
@@ -520,9 +525,11 @@
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CODE_SIGN_IDENTITY = "-";
COPY_PHASE_STRIP = NO;
+ DEAD_CODE_STRIPPING = YES;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
+ ENABLE_USER_SCRIPT_SANDBOXING = NO;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
@@ -550,6 +557,7 @@
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
+ ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
@@ -573,9 +581,11 @@
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CODE_SIGN_IDENTITY = "-";
COPY_PHASE_STRIP = NO;
+ DEAD_CODE_STRIPPING = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
+ ENABLE_USER_SCRIPT_SANDBOXING = NO;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
diff --git a/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme
index c136c3c..1ea4087 100644
--- a/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme
+++ b/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme
@@ -1,6 +1,6 @@
Bool {
return true
diff --git a/macos/Runner/Configs/AppInfo.xcconfig b/macos/Runner/Configs/AppInfo.xcconfig
index b27743e..847837e 100644
--- a/macos/Runner/Configs/AppInfo.xcconfig
+++ b/macos/Runner/Configs/AppInfo.xcconfig
@@ -11,4 +11,4 @@ PRODUCT_NAME = flutter_bloc_advance
PRODUCT_BUNDLE_IDENTIFIER = com.cevheri.flutter.flutterBlocAdvance
// The copyright displayed in application information
-PRODUCT_COPYRIGHT = Copyright © 2023 com.cevheri.flutter. All rights reserved.
+PRODUCT_COPYRIGHT = Copyright © 2024 com.cevheri.flutter. All rights reserved.
diff --git a/macos/RunnerTests/RunnerTests.swift b/macos/RunnerTests/RunnerTests.swift
index 5418c9f..61f3bd1 100644
--- a/macos/RunnerTests/RunnerTests.swift
+++ b/macos/RunnerTests/RunnerTests.swift
@@ -1,5 +1,5 @@
-import FlutterMacOS
import Cocoa
+import FlutterMacOS
import XCTest
class RunnerTests: XCTestCase {
diff --git a/pubspec.lock b/pubspec.lock
index 29930f4..d4417f7 100644
--- a/pubspec.lock
+++ b/pubspec.lock
@@ -447,10 +447,10 @@ packages:
dependency: "direct dev"
description:
name: flutter_lints
- sha256: "5398f14efa795ffb7a33e9b6a08798b26a180edac4ad7db3f231e40f82ce11e1"
+ sha256: "3f41d009ba7172d5ff9be5f6e6e6abb4300e263aab8866d2a0842ed2a70f8f0c"
url: "https://pub.dev"
source: hosted
- version: "5.0.0"
+ version: "4.0.0"
flutter_localizations:
dependency: "direct main"
description: flutter
@@ -638,10 +638,10 @@ packages:
dependency: transitive
description:
name: lints
- sha256: "3315600f3fb3b135be672bf4a178c55f274bebe368325ae18462c89ac1e3b413"
+ sha256: "976c774dd944a42e83e2467f4cc670daef7eed6295b10b36ae8c85bcbf828235"
url: "https://pub.dev"
source: hosted
- version: "5.0.0"
+ version: "4.0.0"
logging:
dependency: transitive
description:
@@ -1224,5 +1224,5 @@ packages:
source: hosted
version: "3.1.2"
sdks:
- dart: ">=3.5.3 <4.0.0"
+ dart: ">=3.5.4 <4.0.0"
flutter: ">=3.24.4"
diff --git a/pubspec.yaml b/pubspec.yaml
index f324726..09eb661 100644
--- a/pubspec.yaml
+++ b/pubspec.yaml
@@ -4,7 +4,7 @@ publish_to: 'none'
version: 1.0.0+1
environment:
- sdk: ^3.5.3
+ sdk: ^3.5.4
flutter: '3.24.4'
dependencies:
@@ -46,7 +46,7 @@ dependencies:
dev_dependencies:
flutter_test:
sdk: flutter
- flutter_lints: ^5.0.0
+ flutter_lints: ^4.0.0
build_runner:
test: ^1.25.7
bloc_test: ^9.1.7
diff --git a/test/data/model/user_test.dart b/test/data/model/user_test.dart
index 99a717d..5ba06db 100644
--- a/test/data/model/user_test.dart
+++ b/test/data/model/user_test.dart
@@ -3,15 +3,10 @@ import 'package:flutter_bloc_advance/main/main_local.mapper.g.dart';
import 'package:flutter_test/flutter_test.dart';
void main() {
+ final DateTime createdDate = DateTime(2024, 1, 1);
late User userModel;
- // late String postUserJson;
- // final mockDataPath = 'mock/';
- // final postUserMockData = 'POST_admin_users.json';
- // Initialize Test
- setUp(() {
- initializeJsonMapper();
-
- userModel = User(
+ User initUser() {
+ return User(
id: '1',
login: 'test_login',
firstName: 'John',
@@ -20,11 +15,21 @@ void main() {
activated: true,
langKey: 'en',
createdBy: 'admin',
- createdDate: DateTime(2021, 1, 1),
+ createdDate: createdDate,
lastModifiedBy: 'admin',
- lastModifiedDate: DateTime(2021, 1, 2),
- authorities: ['ROLE_USER'],
+ lastModifiedDate: createdDate,
+ authorities: const ['ROLE_USER'],
);
+ }
+
+ // late String postUserJson;
+ // final mockDataPath = 'mock/';
+ // final postUserMockData = 'POST_admin_users.json';
+ // Initialize Test
+ setUp(() {
+ initializeJsonMapper();
+
+ userModel = initUser();
});
group('User Model', () {
@@ -39,9 +44,9 @@ void main() {
expect(finalUser.activated, true);
expect(finalUser.langKey, 'en');
expect(finalUser.createdBy, 'admin');
- expect(finalUser.createdDate, DateTime(2021, 1, 1));
+ expect(finalUser.createdDate, createdDate);
expect(finalUser.lastModifiedBy, 'admin');
- expect(finalUser.lastModifiedDate, DateTime(2021, 1, 2));
+ expect(finalUser.lastModifiedDate, createdDate);
expect(finalUser.authorities, ['ROLE_USER']);
});
@@ -61,14 +66,15 @@ void main() {
expect(updatedUser.activated, true);
expect(updatedUser.langKey, 'en');
expect(updatedUser.createdBy, 'admin');
- expect(updatedUser.createdDate, DateTime(2021, 1, 1));
+ expect(updatedUser.createdDate, createdDate);
expect(updatedUser.lastModifiedBy, 'admin');
- expect(updatedUser.lastModifiedDate, DateTime(2021, 1, 2));
+ expect(updatedUser.lastModifiedDate, createdDate);
expect(updatedUser.authorities, ['ROLE_USER']);
});
test('should deserialize from JSON', () {
- const json = {
+ final createdDateString = createdDate.toIso8601String();
+ final json = {
'id': '1',
'login': 'test_login',
'firstName': 'John',
@@ -77,9 +83,9 @@ void main() {
'activated': true,
'langKey': 'en',
'createdBy': 'admin',
- 'createdDate': '2021-01-01T00:00:00.000Z',
+ 'createdDate': createdDateString,
'lastModifiedBy': 'admin',
- 'lastModifiedDate': '2021-01-02T00:00:00.000Z',
+ 'lastModifiedDate': createdDateString,
'authorities': ['ROLE_USER'],
};
@@ -93,16 +99,17 @@ void main() {
expect(finalUser?.activated, true);
expect(finalUser?.langKey, 'en');
expect(finalUser?.createdBy, 'admin');
- expect(finalUser?.createdDate, DateTime.parse('2021-01-01T00:00:00.000Z'));
+ expect(finalUser?.createdDate, createdDate);
expect(finalUser?.lastModifiedBy, 'admin');
- expect(finalUser?.lastModifiedDate, DateTime.parse('2021-01-02T00:00:00.000Z'));
+ expect(finalUser?.lastModifiedDate, createdDate);
expect(finalUser?.authorities, ['ROLE_USER']);
});
test('should deserialize from JSON string', () {
//postUserJson = await rootBundle.loadString(mockDataPath+postUserMockData);
- const jsonString = '''
+ final createdDateString = createdDate.toIso8601String();
+ final jsonString = '''
{
"id": "1",
"login": "test_login",
@@ -112,9 +119,9 @@ void main() {
"activated": true,
"langKey": "en",
"createdBy": "admin",
- "createdDate": "2021-01-01T00:00:00.000Z",
+ "createdDate": "$createdDateString",
"lastModifiedBy": "admin",
- "lastModifiedDate": "2021-01-02T00:00:00.000Z",
+ "lastModifiedDate": "$createdDateString",
"authorities": ["ROLE_USER"]
}
''';
@@ -129,9 +136,9 @@ void main() {
expect(finalUser?.activated, true);
expect(finalUser?.langKey, 'en');
expect(finalUser?.createdBy, 'admin');
- expect(finalUser?.createdDate, DateTime.parse('2021-01-01T00:00:00.000Z'));
+ expect(finalUser?.createdDate, createdDate);
expect(finalUser?.lastModifiedBy, 'admin');
- expect(finalUser?.lastModifiedDate, DateTime.parse('2021-01-02T00:00:00.000Z'));
+ expect(finalUser?.lastModifiedDate, createdDate);
expect(finalUser?.authorities, ['ROLE_USER']);
});
});
diff --git a/web/index.html b/web/index.html
index d7e73c0..17a2a56 100644
--- a/web/index.html
+++ b/web/index.html
@@ -31,15 +31,8 @@
flutter_bloc_advance
-
-
-
-
-
+