fix: 输入校验忽略多个连续空格与大小写;统一中英文引号与空白规范化
This commit is contained in:
@@ -79,4 +79,31 @@ void main() {
|
||||
isTrue,
|
||||
);
|
||||
});
|
||||
|
||||
test('ignores multiple spaces and casing across review items', () {
|
||||
// Multi-space and uppercase on A0-P03
|
||||
expect(
|
||||
ReviewFeedback.check(
|
||||
review('A0-P03', 'Nice to meet you.'),
|
||||
' NICE TO MEET YOU! ',
|
||||
).complete,
|
||||
isTrue,
|
||||
);
|
||||
// Multi-space and uppercase on A0-P08
|
||||
expect(
|
||||
ReviewFeedback.check(
|
||||
review('A0-P08', 'My number is ...'),
|
||||
'MY NUMBER IS ONE TWO THREE',
|
||||
).complete,
|
||||
isTrue,
|
||||
);
|
||||
// Multi-space on word item
|
||||
expect(
|
||||
ReviewFeedback.check(
|
||||
review('A0-W08', 'three'),
|
||||
' THREE ',
|
||||
).complete,
|
||||
isTrue,
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user