Skip to content

Commit 73d70bf

Browse files
authored
test: flutter wasm (#2231)
* test: flutter wasm * temporarily disable failing tests * fixup ci * cleanup
1 parent ba56a96 commit 73d70bf

File tree

2 files changed

+18
-7
lines changed

2 files changed

+18
-7
lines changed

.github/workflows/flutter.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ jobs:
2929
defaults:
3030
run:
3131
shell: bash
32+
working-directory: flutter
3233
strategy:
3334
fail-fast: false
3435
matrix:
@@ -77,21 +78,23 @@ jobs:
7778
- run: flutter upgrade
7879

7980
- name: Pub Get
80-
run: |
81-
cd flutter
82-
flutter pub get
81+
run: flutter pub get
8382

84-
- name: Test chrome
83+
- name: Test web (JS)
8584
if: matrix.target == 'web'
8685
run: |
87-
cd flutter
8886
flutter test --platform chrome --test-randomize-ordering-seed=random --exclude-tags canvasKit
8987
flutter test --platform chrome --test-randomize-ordering-seed=random --tags canvasKit --web-renderer canvaskit
9088
89+
- name: Test web (WASM)
90+
if: matrix.target == 'web'
91+
run: |
92+
flutter test --platform chrome --wasm --test-randomize-ordering-seed=random --exclude-tags canvasKit
93+
flutter test --platform chrome --wasm --test-randomize-ordering-seed=random --tags canvasKit --web-renderer canvaskit
94+
9195
- name: Test VM with coverage
9296
if: matrix.target == 'linux' || matrix.target == 'macos' || matrix.target == 'windows'
9397
run: |
94-
cd flutter
9598
flutter test --coverage --test-randomize-ordering-seed=random
9699
dart run remove_from_coverage -f coverage/lcov.info -r 'binding.dart'
97100
@@ -111,11 +114,11 @@ jobs:
111114
exclude: 'lib/src/native/cocoa/binding.dart'
112115

113116
- name: Build ${{ matrix.target }}
117+
working-directory: flutter/example
114118
run: |
115119
flutter config --enable-windows-desktop
116120
flutter config --enable-macos-desktop
117121
flutter config --enable-linux-desktop
118-
cd flutter/example
119122
TARGET=${{ matrix.target }}
120123
flutter pub get
121124
case $TARGET in

flutter/test/integrations/flutter_error_integration_test.dart

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,10 @@ void main() {
8282
expect(event.contexts['flutter_error_details']['context'],
8383
'thrown while handling a gesture');
8484
expect(event.contexts['flutter_error_details']['information'], 'foo bar');
85+
}, onPlatform: {
86+
// TODO stacktrace parsing for wasm is not implemented yet
87+
// https://github.com/getsentry/sentry-dart/issues/1480
88+
'wasm': Skip('WASM stack trace parsing not implemented yet'),
8589
});
8690

8791
test('captures error with long FlutterErrorDetails.information', () async {
@@ -115,6 +119,10 @@ void main() {
115119
'thrown while handling a gesture');
116120
expect(event.contexts['flutter_error_details']['information'],
117121
'foo bar\nHello World!');
122+
}, onPlatform: {
123+
// TODO stacktrace parsing for wasm is not implemented yet
124+
// https://github.com/getsentry/sentry-dart/issues/1480
125+
'wasm': Skip('WASM stack trace parsing not implemented yet'),
118126
});
119127

120128
test('captures error with no FlutterErrorDetails', () async {

0 commit comments

Comments
 (0)