Skip to content

Commit

Permalink
feat: use current_year as String
Browse files Browse the repository at this point in the history
  • Loading branch information
alestiago committed Aug 29, 2024
1 parent 21f1dc6 commit e81ef01
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion very_good_flame_game/hooks/pre_gen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,6 @@ void run(HookContext context) {
'ios_application_id': configuration.iOsApplicationId,
'macos_application_id': configuration.macOsApplicationId,
'windows_application_id': configuration.windowsApplicationId,
'current_year': clock.now().year,
'current_year': clock.now().year.toString(),
};
}
5 changes: 2 additions & 3 deletions very_good_flame_game/hooks/test/pre_gen_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ void main() {
});

test('populates variables', () {
final clock = Clock.fixed(DateTime(2020));
withClock(clock, () {
withClock(Clock.fixed(DateTime(2020)), () {
final vars = {
'project_name': 'my_game',
'org_name': 'com.example',
Expand All @@ -43,7 +42,7 @@ void main() {
'ios_application_id': 'app.id',
'macos_application_id': 'app.id',
'windows_application_id': 'app.id',
'current_year': clock.now().year,
'current_year': '2020',
},
),
);
Expand Down

0 comments on commit e81ef01

Please sign in to comment.