feat: add Web build test

Signed-off-by: The one with the braid <info@braid.business>
This commit is contained in:
The one with the braid 2024-04-04 12:29:30 +02:00 committed by Krille
parent 4ba6e25689
commit 87c0e7fbe8
No known key found for this signature in database
GPG Key ID: E067ECD60F1A0652
5 changed files with 32 additions and 0 deletions

View File

@ -47,6 +47,11 @@ jobs:
rm -r example
./scripts/prepare.sh
./scripts/test.sh
- name: Ensure SDK compiles on web
run: |
pushd web_test
dart pub get
dart run webdev build
coverage_without_olm:
runs-on: ubuntu-latest

3
web_test/.gitignore vendored Normal file
View File

@ -0,0 +1,3 @@
# https://dart.dev/guides/libraries/private-files
# Created by `dart pub`
.dart_tool/

1
web_test/README.md Normal file
View File

@ -0,0 +1 @@
This is a bare-bone sample project in order to ensure webdev can compile the SDK.

17
web_test/pubspec.yaml Normal file
View File

@ -0,0 +1,17 @@
name: web_test
description: A test project for the webdev compiler.
version: 1.0.0
publish_to: none
environment:
sdk: ^3.2.0
# Add regular dependencies here.
dependencies:
matrix:
path: ..
dev_dependencies:
build_runner: ^2.4.9
build_web_compilers: ^4.0.10
webdev: ^3.4.0

6
web_test/web/main.dart Normal file
View File

@ -0,0 +1,6 @@
import 'package:matrix/matrix.dart';
Future<void> main() async {
final client = Client('web_test');
await client.init();
}