chore(player): 移除飘心毫秒调试文字
This commit is contained in:
1 parent
1b50a73bfc
commit
afdc4af2f2
3 files changed
-30
No files matched your search
@@ -159,18 +159,6 @@ class _PlayerDoubleTapHeartBurstState extends State<PlayerDoubleTapHeartBurst> {
|
||||
children: [
|
||||
for (var index = 0; index < _hearts.length; index++)
|
||||
_heart(_hearts[index], _elapsedMs.toDouble(), index),
|
||||
if (kDebugMode)
|
||||
Positioned(
|
||||
left: widget.origin.dx + 8,
|
||||
top: widget.origin.dy + 10,
|
||||
child: IgnorePointer(
|
||||
child: Text(
|
||||
'${_elapsedMs}ms',
|
||||
key: const Key('heart-burst-elapsed-debug'),
|
||||
style: const TextStyle(color: Colors.white60, fontSize: 11),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
@@ -26,11 +26,6 @@ void main() {
|
||||
expect(_size(tester, 0), 48);
|
||||
expect(_size(tester, 1), 36);
|
||||
expect(_size(tester, 2), 40);
|
||||
final elapsedText = tester
|
||||
.widget<Text>(find.byKey(const Key('heart-burst-elapsed-debug')))
|
||||
.data!;
|
||||
final elapsedMs = int.parse(elapsedText.replaceFirst('ms', ''));
|
||||
expect(elapsedMs, inInclusiveRange(180, 220));
|
||||
expect(
|
||||
tester
|
||||
.widgetList<Stack>(
|
||||
@@ -97,13 +92,6 @@ void main() {
|
||||
(tester.getCenter(firstHeart) - origin).distance,
|
||||
lessThanOrEqualTo(1),
|
||||
);
|
||||
final debugTopLeft = tester.getTopLeft(
|
||||
find.byKey(const Key('heart-burst-elapsed-debug')),
|
||||
);
|
||||
expect(
|
||||
(debugTopLeft - const Offset(308, 556)).distance,
|
||||
lessThanOrEqualTo(1),
|
||||
);
|
||||
|
||||
await _pumpHeartTime(tester, clock, const Duration(milliseconds: 750));
|
||||
final midpoint = tester.getCenter(firstHeart);
|
||||
|
||||
@@ -50,12 +50,6 @@ void main() {
|
||||
expect(firstSize.height, closeTo(48, 1));
|
||||
expect(firstSize.width, greaterThan(20));
|
||||
expect((initialCenter - origin).distance, lessThanOrEqualTo(1));
|
||||
expect(
|
||||
(tester.getTopLeft(find.byKey(const Key('heart-burst-elapsed-debug'))) -
|
||||
const Offset(308, 556))
|
||||
.distance,
|
||||
lessThanOrEqualTo(1),
|
||||
);
|
||||
|
||||
await _pumpHeartTime(tester, clock, const Duration(milliseconds: 300));
|
||||
final center300 = tester.getCenter(firstHeart);
|
||||
|
||||
Reference in new issue
Block a user