Skip to content

Commit 63697a2

Browse files
committed
fix flutter/flutter#24720 warning from flutter analyze deprecated_member_use
1 parent e14f149 commit 63697a2

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

lib/sentry.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ class SentryClient {
197197
List<int> body = utf8.encode(json.encode(data));
198198
if (compressPayload) {
199199
headers['Content-Encoding'] = 'gzip';
200-
body = GZIP.encode(body);
200+
body = gzip.encode(body);
201201
}
202202

203203
final Response response =

test/sentry_test.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,12 +151,12 @@ void main() {
151151

152152
Map<String, dynamic> data;
153153
if (compressPayload) {
154-
data = json.decode(utf8.decode(GZIP.decode(body)));
154+
data = json.decode(utf8.decode(gzip.decode(body)));
155155
} else {
156156
data = json.decode(utf8.decode(body));
157157
}
158158
final Map<String, dynamic> stacktrace = data.remove('stacktrace');
159-
expect(stacktrace['frames'], const isInstanceOf<List>());
159+
expect(stacktrace['frames'], const TypeMatcher<List>());
160160
expect(stacktrace['frames'], isNotEmpty);
161161

162162
final Map<String, dynamic> topFrame =

test/version_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ void main() {
1212
group('sdkVersion', () {
1313
test('matches that of pubspec.yaml', () {
1414
final dynamic pubspec =
15-
yaml.loadYaml(new File('pubspec.yaml').readAsStringSync());
15+
yaml.loadYaml(new File('../pubspec.yaml').readAsStringSync());
1616
expect(sdkVersion, pubspec['version']);
1717
});
1818
});

0 commit comments

Comments
 (0)