Skip to content

Commit dde9f62

Browse files
authored
ci: update ci workflow to use rps (#1078)
1 parent b743ba1 commit dde9f62

File tree

3 files changed

+12
-15
lines changed

3 files changed

+12
-15
lines changed

.github/workflows/ci.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,23 @@ on:
77
- ".github/**"
88
- ".vscode/**"
99
- "README.md"
10-
workflow_dispatch:
1110

1211
jobs:
1312
build:
1413
runs-on: ubuntu-latest
15-
container:
16-
image: ghcr.io/cirruslabs/flutter:3.35.5
1714

1815
steps:
1916
- name: Checkout OneSignal-Flutter-SDK
2017
uses: actions/checkout@v5
2118

22-
- name: Install Dependencies 🔗⛓📦
19+
- name: Set up Flutter
20+
uses: subosito/flutter-action@v2
21+
with:
22+
channel: stable
23+
flutter-version: 3.35.5
24+
cache: true
25+
26+
- name: Install
2327
run: flutter pub get
2428

2529
- name: Static Analysis
@@ -29,4 +33,4 @@ jobs:
2933
run: dart format --set-exit-if-changed --output=none .
3034

3135
- name: Run Flutter unit tests
32-
run: flutter test
36+
run: dart run rps test

pubspec.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ version: 5.3.4
44
homepage: https://github.com/OneSignal/OneSignal-Flutter-SDK
55

66
scripts:
7-
test: dlcov -c 80 --lcov-gen="flutter test --coverage" --include-untested-files=true
7+
test: flutter test --coverage && dart run dlcov -c 80 --log=0 --include-untested-files=true
88

99
flutter:
1010
plugin:
@@ -27,5 +27,5 @@ dev_dependencies:
2727
rps: ^0.9.1
2828

2929
environment:
30-
sdk: ">=2.12.0 <3.0.0"
31-
flutter: ">=1.10.0"
30+
sdk: ">=3.0.0 <4.0.0"
31+
flutter: ">=3.0.0"

test/mock_channel.dart

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -125,10 +125,6 @@ class OneSignalMockChannelController {
125125
case "OneSignal#removeExternalUserId":
126126
state.externalId = null;
127127
return {"success": true};
128-
case "OneSignal#setLanguage":
129-
state.language =
130-
(call.arguments as Map<dynamic, dynamic>)['language'] as String?;
131-
return {"success": true};
132128
case "OneSignal#requestPermission":
133129
// Location requestPermission (no arguments)
134130
if (call.arguments == null) {
@@ -204,9 +200,6 @@ class OneSignalMockChannelController {
204200
break;
205201
case "OneSignal#arePaused":
206202
return state.inAppMessagesPaused ?? false;
207-
case "OneSignal#lifecycleInit":
208-
state.lifecycleInitCalled = true;
209-
break;
210203
case "OneSignal#displayNotification":
211204
// This is called on OneSignal#notifications channel
212205
state.displayedNotificationId = (call.arguments

0 commit comments

Comments
 (0)