Skip to content

Commit

Permalink
chore: Change test's naming pattern
Browse files Browse the repository at this point in the history
  • Loading branch information
martynov-alex committed Feb 13, 2024
1 parent 9f45b07 commit 9059ed7
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/utils/test_widget.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// ignore_for_file: comment_references, depend_on_referenced_packages

import 'package:flutter/material.dart';

import 'package:flutter_test/flutter_test.dart';
import 'package:golden_toolkit/golden_toolkit.dart';
import 'package:meta/meta.dart';
Expand Down Expand Up @@ -130,7 +129,10 @@ String _getGoldenName<T>(

final formattedState = state?.trim().replaceAll(' ', '_');

return '${includeThemeName ? theme.stringified : 'no_theme'}${locale == null ? '' : '.${locale.languageCode}'}${formattedState == null ? '' : '.$formattedState'}.$name';
return '$name.'
'${formattedState == null ? '' : '$formattedState.'}'
'${locale == null ? '' : '${locale.languageCode}.'}'
'${includeThemeName ? theme.stringified : 'no_theme'}';
}

enum ThemeType {
Expand Down

0 comments on commit 9059ed7

Please sign in to comment.