Skip to content

Commit 1640a67

Browse files
committed
Format tests for the CI dart format check
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AjsYaRkTHNKszSHjd3j264
1 parent 91bd8b7 commit 1640a67

4 files changed

Lines changed: 23 additions & 19 deletions

File tree

‎test/industrial_slider_json_test.dart‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ void main() {
2323
selectableMax: 95,
2424
),
2525
);
26-
final back = NodeJsonConverter.instance.fromJson(node.toJson()) as SliderNode;
26+
final back =
27+
NodeJsonConverter.instance.fromJson(node.toJson()) as SliderNode;
2728
expect(back.markerValue, 87);
2829
expect(back.properties, node.properties);
2930
expect(back.triggerTypes, contains(TriggerType.changeEnd));

‎test/interval_trigger_test.dart‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,10 @@ void main() {
2424

2525
test('periods shorter than the minimum are clamped', () {
2626
expect(
27-
TriggerModel(type: TriggerType.interval, intervalMillis: 5)
28-
.effectiveIntervalMillis,
27+
TriggerModel(
28+
type: TriggerType.interval,
29+
intervalMillis: 5,
30+
).effectiveIntervalMillis,
2931
TriggerModel.minIntervalMillis,
3032
);
3133
});

‎test/nodes/node_transition_json_test.dart‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,10 @@ void main() {
2222
'transition': {'durationMillis': 1100, 'curve': 'easeInOut'},
2323
};
2424
final BaseNode node = NodeJsonConverter().fromJson(json)!;
25-
expect((node as BlendMixin).transition,
26-
const NodeTransition(durationMillis: 1100));
25+
expect(
26+
(node as BlendMixin).transition,
27+
const NodeTransition(durationMillis: 1100),
28+
);
2729
final BaseNode again = NodeJsonConverter().fromJson(node.toJson())!;
2830
expect((again as BlendMixin).transition?.durationMillis, 1100);
2931
expect(const NodeTransition().toJson(), isEmpty);

‎test/row_column_wrap_test.dart‎

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,16 @@ import 'dart:convert';
33
import 'package:codelessly_api/codelessly_api.dart';
44
import 'package:test/test.dart';
55

6-
RowColumnNode _row({bool wrap = false, double runSpacing = 0}) =>
7-
RowColumnNode(
8-
id: 'row',
9-
name: 'Row',
10-
basicBoxLocal: NodeBox(0, 0, 330, 100),
11-
children: const ['a', 'b', 'c'],
12-
rowColumnType: RowColumnType.row,
13-
spacing: 8,
14-
wrap: wrap,
15-
runSpacing: runSpacing,
16-
);
6+
RowColumnNode _row({bool wrap = false, double runSpacing = 0}) => RowColumnNode(
7+
id: 'row',
8+
name: 'Row',
9+
basicBoxLocal: NodeBox(0, 0, 330, 100),
10+
children: const ['a', 'b', 'c'],
11+
rowColumnType: RowColumnType.row,
12+
spacing: 8,
13+
wrap: wrap,
14+
runSpacing: runSpacing,
15+
);
1716

1817
void main() {
1918
group('RowColumnNode wrap', () {
@@ -27,9 +26,9 @@ void main() {
2726
});
2827

2928
test('round-trips wrap and runSpacing', () {
30-
final json =
31-
jsonDecode(jsonEncode(_row(wrap: true, runSpacing: 12).toJson()))
32-
as Map;
29+
final json = jsonDecode(
30+
jsonEncode(_row(wrap: true, runSpacing: 12).toJson()),
31+
) as Map;
3332
expect(json['wrap'], isTrue);
3433
expect(json['runSpacing'], 12);
3534
final decoded = RowColumnNode.fromJson(json);

0 commit comments

Comments
 (0)