Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions .github/workflows/integration_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ jobs:
- name: Run integration tests
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: 29
emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none -no-metrics
disable-animations: true
api-level: 34
arch: x86_64
working-directory: counter_app
script: flutter test integration_test
script: flutter test integration_test -d emulator-5554
1 change: 1 addition & 0 deletions test/generate_widget_matchers.dart
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ void main() {
);
_generateWidget<Radio<String>>(
builder: () =>
// ignore: deprecated_member_use
Radio<String>(value: 'a', groupValue: 'a', onChanged: (_) {}),
imports: "import 'package:flutter/material.dart';",
);
Expand Down
17 changes: 13 additions & 4 deletions test/widgets/text_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,7 @@ void main() {
await tester.pumpWidget(
_stage(
children: [
ColoredBox(
color: Colors.red,
_MyWidget(
child: Text('a'),
),
RotatedBox(
Expand All @@ -197,10 +196,10 @@ void main() {
),
);

spot<ColoredBox>().spotText('a').existsOnce();
spot<_MyWidget>().spotText('a').existsOnce();
spot<RotatedBox>().spotText('b').existsOnce();

spot<ColoredBox>().spotText('b').doesNotExist();
spot<_MyWidget>().spotText('b').doesNotExist();
spot<RotatedBox>().spotText('a').doesNotExist();
});
});
Expand Down Expand Up @@ -406,3 +405,13 @@ Widget _stage({required List<Widget> children}) {
),
);
}

class _MyWidget extends StatelessWidget {
const _MyWidget({required this.child});

final Widget child;
@override
Widget build(BuildContext context) {
return child;
}
}
Loading