$ show flutter/tests
This repository serves as the customer test registry for the Flutter framework. It contains .test configuration files in the `registry/` directory that define how to fetch, update, and run tests from external Flutter packages (e.g., flame, provider, devtools) in CI. These tests are executed with every Flutter commit to detect regressions. The repository also includes a separate `skp_generator` Flutter application that generates SKP files of Flutter scenes for Skia's use in regression and performance testing. The codebase is implemented primarily as shell scripts (bash/batch), GitHub Actions workflows, and a small Dart program. It is not a reusable library but rather an operational glue repository for integrating third-party Flutter tests into the Flutter CI pipeline. The architecture is simple: test definitions (key-value format) are parsed by a Dart runner (`dev/customer_testing/run_tests.dart` in the Flutter repo) which fetches, updates, and runs the tests as per the directives. The SKP generator is a separate utility with its own build script and Dart code for scene rendering.
The LLM identified 2 files worth highlighting for reuse:
This is the template for defining a customer test. It specifies contacts, fetch commands (git clone), update paths, setup commands, and test commands (flutter analyze, flutter test). The format is straightforward but demonstrates a clean, declarative way to integrate external repositories into CI. It is reusable as a configuration pattern for any project that needs to define external test suites in a structured way.
This Dart program generates Skia picture (SKP) files from Flutter widgets for performance and regression testing. It connects to the Flutter VM service, renders each widget to a scene, captures the Skia picture via `_flutter.screenshotSkp` extension, and saves it as .skp files. It includes a `StoryBoard` widget to tile multiple variants of a test widget, and a test screen that cycles through predefined widget sets. This demonstrates a non-obvious use of Flutter's VM service for graphics capture and is a specialized tool for Skia engineers.