Skip to content

Commit aa1de32

Browse files
authored
[unified_analytics] Deprecate flutterWasmDryRun (#2306)
1 parent 93bf967 commit aa1de32

File tree

6 files changed

+9
-43
lines changed

6 files changed

+9
-43
lines changed

pkgs/unified_analytics/CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
## 8.0.13
2+
- Deprecated `Event.flutterWasmDryRun` in favor of `Event.flutterWasmDryRunPackage`.
3+
14
## 8.0.12
25
- Added `Event.plugins` to track new analyzer plugins
36

pkgs/unified_analytics/lib/src/constants.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ const int kMaxLogFileSize = 25 * (1 << 20);
8787
const String kLogFileName = 'dart-flutter-telemetry.log';
8888

8989
/// The current version of the package, should be in line with pubspec version.
90-
const String kPackageVersion = '8.0.12';
90+
const String kPackageVersion = '8.0.13';
9191

9292
/// The minimum length for a session.
9393
const int kSessionDurationMinutes = 30;

pkgs/unified_analytics/lib/src/enums.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,8 @@ enum DashEvent {
103103
description: 'Provides information about flutter commands that ran',
104104
toolOwner: DashTool.flutterTool,
105105
),
106+
@Deprecated("Use 'flutterWasmDryRunPackage' instead. This will be removed in "
107+
'a future version.')
106108
flutterWasmDryRun(
107109
label: 'wasm_dry_run',
108110
description: 'Information for a dart2wasm dry run invoked from Flutter',

pkgs/unified_analytics/lib/src/event.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -660,6 +660,8 @@ final class Event {
660660
},
661661
);
662662

663+
@Deprecated("Use 'flutterWasmDryRunPackage' instead. This will be removed in "
664+
'a future version.')
663665
Event.flutterWasmDryRun({
664666
required String result,
665667
required int exitCode,

pkgs/unified_analytics/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ description: >-
55
# LINT.IfChange
66
# When updating this, keep the version consistent with the changelog and the
77
# value in lib/src/constants.dart.
8-
version: 8.0.12
8+
version: 8.0.13
99
# LINT.ThenChange(lib/src/constants.dart)
1010
repository: https://github.com/dart-lang/tools/tree/main/pkgs/unified_analytics
1111
issue_tracker: https://github.com/dart-lang/tools/issues?q=is%3Aissue+is%3Aopen+label%3Apackage%3Aunified_analytics

pkgs/unified_analytics/test/event_test.dart

Lines changed: 0 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -477,47 +477,6 @@ void main() {
477477
expect(constructedEvent.eventData.length, 4);
478478
});
479479

480-
test('Event.flutterWasmDryRun constructed no findings', () {
481-
Event generateEventNoFindings() => Event.flutterWasmDryRun(
482-
result: 'success',
483-
exitCode: 123,
484-
);
485-
486-
final constructedEvent1 = generateEventNoFindings();
487-
488-
expect(generateEventNoFindings, returnsNormally);
489-
expect(constructedEvent1.eventName, DashEvent.flutterWasmDryRun);
490-
expect(constructedEvent1.eventData['result'], 'success');
491-
expect(constructedEvent1.eventData['exitCode'], 123);
492-
expect(constructedEvent1.eventData.length, 2);
493-
});
494-
test('Event.flutterWasmDryRun constructed with findings', () {
495-
Event generateEventNoFindings() => Event.flutterWasmDryRun(
496-
result: 'success',
497-
exitCode: 123,
498-
);
499-
500-
final constructedEvent1 = generateEventNoFindings();
501-
502-
expect(generateEventNoFindings, returnsNormally);
503-
expect(constructedEvent1.eventName, DashEvent.flutterWasmDryRun);
504-
expect(constructedEvent1.eventData['result'], 'success');
505-
expect(constructedEvent1.eventData['exitCode'], 123);
506-
expect(constructedEvent1.eventData.length, 2);
507-
508-
Event generateEventFindings() => Event.flutterWasmDryRun(
509-
result: 'success', exitCode: 123, findingsSummary: '1,2,3');
510-
511-
final constructedEvent2 = generateEventFindings();
512-
513-
expect(generateEventFindings, returnsNormally);
514-
expect(constructedEvent2.eventName, DashEvent.flutterWasmDryRun);
515-
expect(constructedEvent2.eventData['result'], 'success');
516-
expect(constructedEvent2.eventData['exitCode'], 123);
517-
expect(constructedEvent2.eventData['findings'], '1,2,3');
518-
expect(constructedEvent2.eventData.length, 3);
519-
});
520-
521480
test('Event.flutterWasmDryRunPackage constructed', () {
522481
Event generateEvent() => Event.flutterWasmDryRunPackage(
523482
result: 'success',

0 commit comments

Comments
 (0)