-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into ni/object-schema
* main: Switch to integration tests (#1461) Always use persistent handles when passing dart objects as userdata to callbacks (#1491) # Conflicts: # test/dynamic_realm_test.dart
- Loading branch information
Showing
115 changed files
with
972 additions
and
735 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -321,9 +321,23 @@ jobs: | |
|
||
- name: Run tests on iOS Simulator | ||
run: | | ||
flutter drive --target=test_driver/app.dart --dart-define=testName="" --suppress-analytics --debug | ||
flutter test integration_test/all_tests.dart \ | ||
--dart-define=BAAS_BAASAAS_API_KEY=$BAAS_BAASAAS_API_KEY \ | ||
--dart-define=BAAS_DIFFERENTIATOR=$BAAS_DIFFERENTIATOR \ | ||
--file-reporter=json:test-results.json \ | ||
--suppress-analytics | ||
working-directory: ./flutter/realm_flutter/tests | ||
|
||
- name: Publish Test Report | ||
uses: dorny/[email protected] | ||
if: success() || failure() | ||
with: | ||
name: Test Results Flutter iOS | ||
path: test-results.json | ||
reporter: dart-json | ||
only-summary: true | ||
working-directory: ./flutter/realm_flutter/tests | ||
|
||
cleanup-cluster-flutter-ios: | ||
name: Cleanup Cluster for Flutter iOS | ||
uses: ./.github/workflows/terminate-baas.yml | ||
|
@@ -342,7 +356,7 @@ jobs: | |
differentiator: fa${{ github.run_id }}${{ github.run_attempt }} | ||
|
||
flutter-tests-android: | ||
runs-on: macos-latest | ||
runs-on: ubuntu-latest | ||
name: Flutter Tests Android | ||
timeout-minutes: 45 | ||
needs: | ||
|
@@ -358,6 +372,15 @@ jobs: | |
with: | ||
submodules: 'recursive' | ||
|
||
- name: Enable KVM | ||
run: | | ||
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules | ||
sudo udevadm control --reload-rules | ||
sudo udevadm trigger --name-match=kvm | ||
- name: Gradle cache | ||
uses: gradle/gradle-build-action@v2 | ||
|
||
- name: Set up Java | ||
uses: actions/setup-java@v3 | ||
with: | ||
|
@@ -411,7 +434,17 @@ jobs: | |
ndk: 21.0.6113669 | ||
arch: x86 | ||
cmake: 3.10.2.4988404 | ||
script: flutter build apk --debug --target=test_driver/app.dart && flutter install --debug && flutter drive --target=test_driver/app.dart --dart-define=testName="" --suppress-analytics --debug | ||
script: flutter test integration_test/all_tests.dart --dart-define=BAAS_BAASAAS_API_KEY=$BAAS_BAASAAS_API_KEY --dart-define=BAAS_DIFFERENTIATOR=$BAAS_DIFFERENTIATOR --file-reporter=json:test-results.json --suppress-analytics | ||
working-directory: ./flutter/realm_flutter/tests | ||
|
||
- name: Publish Test Report | ||
uses: dorny/[email protected] | ||
if: success() || failure() | ||
with: | ||
name: Test Results Flutter Android | ||
path: test-results.json | ||
reporter: dart-json | ||
only-summary: true | ||
working-directory: ./flutter/realm_flutter/tests | ||
|
||
cleanup-cluster-flutter-android: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -72,5 +72,23 @@ jobs: | |
if: ${{ contains(inputs.os, 'macos') }} | ||
|
||
- name: Run tests | ||
run: ${{ inputs.os == 'linux' && 'xvfb-run' || '' }} flutter drive -d ${{ inputs.os }} --target=test_driver/app.dart --suppress-analytics --dart-entrypoint-args="" --debug # -a="Some test name" | ||
run: | | ||
${{ inputs.os == 'linux' && 'xvfb-run' || '' }} \ | ||
flutter test integration_test/all_tests.dart \ | ||
--dart-define=BAAS_BAASAAS_API_KEY=$BAAS_BAASAAS_API_KEY \ | ||
--dart-define=BAAS_DIFFERENTIATOR=$BAAS_DIFFERENTIATOR \ | ||
--device-id=${{ inputs.os }} \ | ||
--file-reporter=json:test-results.json \ | ||
--suppress-analytics | ||
shell: bash | ||
working-directory: ./flutter/realm_flutter/tests | ||
|
||
- name: Publish Test Report | ||
uses: dorny/[email protected] | ||
if: success() || failure() | ||
with: | ||
name: Test Results Flutter ${{ inputs.os }} ${{ inputs.architecture }} | ||
path: test-results.json | ||
reporter: dart-json | ||
only-summary: true | ||
working-directory: ./flutter/realm_flutter/tests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
flutter/realm_flutter/tests/android/app/src/debug/AndroidManifest.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 0 additions & 6 deletions
6
flutter/realm_flutter/tests/android/app/src/main/java/io/tests/MainActivity.java
This file was deleted.
Oops, something went wrong.
6 changes: 6 additions & 0 deletions
6
flutter/realm_flutter/tests/android/app/src/main/kotlin/io/realm/tests/MainActivity.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package io.realm.tests | ||
|
||
import io.flutter.embedding.android.FlutterActivity | ||
|
||
class MainActivity: FlutterActivity() { | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
flutter/realm_flutter/tests/android/app/src/profile/AndroidManifest.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.