Skip to content

Commit 92c3222

Browse files
committed
Chore: Use named constants
1 parent 948e90a commit 92c3222

File tree

3 files changed

+9
-18
lines changed

3 files changed

+9
-18
lines changed

pubspec.lock

+2-2
Original file line numberDiff line numberDiff line change
@@ -313,10 +313,10 @@ packages:
313313
dependency: "direct dev"
314314
description:
315315
name: golden_screenshot
316-
sha256: "03b34656154b7e08125de8671962f4862b08ea1f57522d32a16fce4b71a1f394"
316+
sha256: "7e939af2e309265937dbce348b573d01fdd5085bb72b721cb8be32736fa26b82"
317317
url: "https://pub.dev"
318318
source: hosted
319-
version: "3.0.0"
319+
version: "3.0.1"
320320
golden_toolkit:
321321
dependency: transitive
322322
description:

pubspec.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ dev_dependencies:
7575
flutter_test:
7676
sdk: flutter
7777

78-
golden_screenshot: ^3.0.0
78+
golden_screenshot: ^3.0.1
7979

8080
icons_launcher: ^3.0.0
8181

test/game_golden_test.dart

+6-15
Original file line numberDiff line numberDiff line change
@@ -96,45 +96,36 @@ void main() {
9696
ShopItems.bulletColors[7].purchase(noCost: true);
9797
ShopItems.bulletColors[9].purchase(noCost: true);
9898

99-
const darkFrameIcons = ScreenshotFrameColors(
100-
topBarIconBrightness: Brightness.dark,
101-
gestureHintBrightness: Brightness.dark,
102-
);
103-
const lightFrameIcons = ScreenshotFrameColors(
104-
topBarIconBrightness: Brightness.light,
105-
gestureHintBrightness: Brightness.light,
106-
);
107-
10899
_testGame(
109-
frameColors: darkFrameIcons,
100+
frameColors: ScreenshotFrameColors.dark,
110101
goldenFileName: '1_home',
111102
child: const HomePage(),
112103
);
113104
_testGame(
114105
gameSave: inProgressGameSave,
115-
frameColors: lightFrameIcons,
106+
frameColors: ScreenshotFrameColors.light,
116107
goldenFileName: '2_play',
117108
child: const PlayPage(),
118109
);
119110
// _testGame(
120111
// gameSave: gameOverGameSave,
121-
// frameColors: darkFrameIcons,
112+
// frameColors: ScreenshotFrameColors.dark,
122113
// goldenFileName: '3_game_over',
123114
// child: const PlayPage(),
124115
// );
125116
_testGame(
126117
goldenFileName: '4_shop',
127-
frameColors: darkFrameIcons,
118+
frameColors: ScreenshotFrameColors.dark,
128119
child: const ShopPage(),
129120
);
130121
_testGame(
131122
goldenFileName: '5_tutorial',
132-
frameColors: darkFrameIcons,
123+
frameColors: ScreenshotFrameColors.dark,
133124
child: const TutorialPage(),
134125
);
135126
_testGame(
136127
goldenFileName: '6_settings',
137-
frameColors: darkFrameIcons,
128+
frameColors: ScreenshotFrameColors.dark,
138129
child: const SettingsPage(),
139130
);
140131
});

0 commit comments

Comments
 (0)