Skip to content

Repository files navigation


check-code-qualityLicense

WidgetDriver is a Flutter presentation layer framework,
which will clean up your widget code, make your widgets more maintainable and easier to test, and removes the need to mock thousands of dependencies in your widget tests.
Let's go driving! 🚙💨

The WidgetDriver framework is built up on different dart packages. The core package which contains the actual framework is the widget_driver. Then there are some helper packages which support with code generation and making testing easier.

Here is an overview of all the packages:

widget_driver pub package

The core package which provides the WidgetDriver framework.

Import it into your pubspec dependencies: section.

widget_driver_generator pub package

The package providing generators to automate the creation of your TestDrivers and WidgetDriverProviders.

Import it into your pubspec dev_dependencies: section.

widget_driver_annotation pub package

The annotation package which has no dependencies.

You do not need to import this since the widget_driver package already imports it for you.
But if you need/want to import it then import it into your pubspec dependencies: section.

widget_driver_test pub package

Contains helper classes/methods to support with:

  • Testing your DrivableWidgets
  • Testing your WidgetDrivers
  • Mocking your TestDrivers

Import it into your pubspec dev_dependencies: section.

example

A Flutter example app showing how to set up all dependencies and how to use the WidgetDriver framework and how to test your widgets and drivers.

Contribute

So you're thinking about supporting us and contributing to the WidgetDriver package. That's great 😀

The first step is to read our contributing guide.

Helpful commands

Makefile file located in the repository root can give you an insight of all available targets which can help you in your development.

Following Makefile targets are available in the project:

all Run all steps including building the Android and iOS
build Build the example Android and iOS apps from the widget_driver package
build_android Run the Android build of the example app (located inside `widget_driver/example`) without deploying to any device
build_ios Run the iOS build of the example app (located inside `widget_driver/example`) without deploying to any device
clean Clean all the cache and dependencies from dart modules.
example_run_build_runner Generate code for the example app inside the widget_driver folder.
format Format all Dart files in the project with the line length set to 120
help Show all commands
install Fetch all dependencies for all packages
lint Run flutter lint in all projects
publish publish all projects to pub.dev
quality Run only linter and tests
test Run all tests in all projects
watch Starts the example app and performs the hot reload incase of any change

Publish to pub.dev

To make the plugins accessible, we plan to publish them to pub.dev. The first step in this process is to create Git tags, which is required for publishing. This can be done by triggering the create-git-tags-for-publishing.yml workflow. This action generates Git tags for all packages in the repository

The second step is to publish the tagged packages to pub.dev, which can be done by triggering the publish-package.yml workflow.

About

A Flutter presentation layer framework

Resources

Code of conduct

Contributing

Stars

22 stars

Watchers

11 watching

Forks

Releases

Packages

Used by

Contributors

Languages