Skip to content

Commit

Permalink
Fix text theme dart fix cases (#125052)
Browse files Browse the repository at this point in the history
Fixes #125049

This is blocking the dart roll, dart fix will now fix some invalid code that was in these test cases. These test case files are un-analyzed intentionally because they are by nature samples of broken code.
  • Loading branch information
Piinks committed Apr 18, 2023
1 parent d4e1209 commit 42fb0b2
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 16 deletions.
16 changes: 8 additions & 8 deletions packages/flutter/test_fixes/material/text_theme.dart
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import 'package:flutter/material.dart';

void main() {
// Changes made in https://github.com/flutter/flutter/pull/48547
var TextTheme textTheme = TextTheme(
var textTheme = TextTheme(
display4: displayStyle4,
display3: displayStyle3,
display2: displayStyle2,
Expand All @@ -21,10 +21,10 @@ void main() {
subtitle: subtitleStyle,
overline: overlineStyle,
);
var TextTheme textTheme = TextTheme(error: '');
var errorTextTheme = TextTheme(error: '');

// Changes made in https://github.com/flutter/flutter/pull/48547
var TextTheme copiedTextTheme = TextTheme.copyWith(
var copiedTextTheme = TextTheme.copyWith(
display4: displayStyle4,
display3: displayStyle3,
display2: displayStyle2,
Expand All @@ -39,7 +39,7 @@ void main() {
subtitle: subtitleStyle,
overline: overlineStyle,
);
var TextTheme copiedTextTheme = TextTheme.copyWith(error: '');
var errorCopiedTextTheme = TextTheme.copyWith(error: '');

// Changes made in https://github.com/flutter/flutter/pull/48547
var style;
Expand All @@ -58,7 +58,7 @@ void main() {
style = textTheme.overline;

// Changes made in https://github.com/flutter/flutter/pull/109817
var TextTheme textTheme = TextTheme(
var anotherTextTheme = TextTheme(
headline1: headline1Style,
headline2: headline2Style,
headline3: headline3Style,
Expand All @@ -73,10 +73,10 @@ void main() {
button: buttonStyle,
overline: overlineStyle,
);
var TextTheme textTheme = TextTheme(error: '');
var anotherErrorTextTheme = TextTheme(error: '');

// Changes made in https://github.com/flutter/flutter/pull/109817
var TextTheme copiedTextTheme = TextTheme.copyWith(
var anotherCopiedTextTheme = TextTheme.copyWith(
headline1: headline1Style,
headline2: headline2Style,
headline3: headline3Style,
Expand All @@ -91,7 +91,7 @@ void main() {
button: buttonStyle,
overline: overlineStyle,
);
var TextTheme copiedTextTheme = TextTheme.copyWith(error: '');
var anotherErrorCopiedTextTheme = TextTheme.copyWith(error: '');

// Changes made in https://github.com/flutter/flutter/pull/109817
var style;
Expand Down
16 changes: 8 additions & 8 deletions packages/flutter/test_fixes/material/text_theme.dart.expect
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import 'package:flutter/material.dart';

void main() {
// Changes made in https://github.com/flutter/flutter/pull/48547
var TextTheme textTheme = TextTheme(
var textTheme = TextTheme(
displayLarge: displayStyle4,
displayMedium: displayStyle3,
displaySmall: displayStyle2,
Expand All @@ -21,10 +21,10 @@ void main() {
titleSmall: subtitleStyle,
labelSmall: overlineStyle,
);
var TextTheme textTheme = TextTheme(error: '');
var errorTextTheme = TextTheme(error: '');

// Changes made in https://github.com/flutter/flutter/pull/48547
var TextTheme copiedTextTheme = TextTheme.copyWith(
var copiedTextTheme = TextTheme.copyWith(
displayLarge: displayStyle4,
displayMedium: displayStyle3,
displaySmall: displayStyle2,
Expand All @@ -39,7 +39,7 @@ void main() {
titleSmall: subtitleStyle,
labelSmall: overlineStyle,
);
var TextTheme copiedTextTheme = TextTheme.copyWith(error: '');
var errorCopiedTextTheme = TextTheme.copyWith(error: '');

// Changes made in https://github.com/flutter/flutter/pull/48547
var style;
Expand All @@ -58,7 +58,7 @@ void main() {
style = textTheme.labelSmall;

// Changes made in https://github.com/flutter/flutter/pull/109817
var TextTheme textTheme = TextTheme(
var anotherTextTheme = TextTheme(
displayLarge: headline1Style,
displayMedium: headline2Style,
displaySmall: headline3Style,
Expand All @@ -73,10 +73,10 @@ void main() {
labelLarge: buttonStyle,
labelSmall: overlineStyle,
);
var TextTheme textTheme = TextTheme(error: '');
var anotherErrorTextTheme = TextTheme(error: '');

// Changes made in https://github.com/flutter/flutter/pull/109817
var TextTheme copiedTextTheme = TextTheme.copyWith(
var anotherCopiedTextTheme = TextTheme.copyWith(
displayLarge: headline1Style,
displayMedium: headline2Style,
displaySmall: headline3Style,
Expand All @@ -91,7 +91,7 @@ void main() {
labelLarge: buttonStyle,
labelSmall: overlineStyle,
);
var TextTheme copiedTextTheme = TextTheme.copyWith(error: '');
var anotherErrorCopiedTextTheme = TextTheme.copyWith(error: '');

// Changes made in https://github.com/flutter/flutter/pull/109817
var style;
Expand Down

0 comments on commit 42fb0b2

Please sign in to comment.