mattermost-push-plugin/example
2026-05-25 14:53:54 +09:00
..
android initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
integration_test initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
ios initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
lib initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
macos initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
test initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
.gitignore initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
analysis_options.yaml initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
pubspec.lock initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
pubspec.yaml initial commit: mattermost-push-plugin 2026-05-25 13:45:37 +09:00
README.md chore: update .gitignore, README, and add agent-ops roadmap 2026-05-25 14:53:54 +09:00

mattermost_push_plugin_example

Thin Flutter app for exercising mattermost_push_plugin independently from any real consuming product app.

Purpose

This app is the repository's integration test harness. Keep it small and focused on proving the plugin contract:

  • plugin registration in a real Flutter application
  • method-channel calls from Dart to the native plugin
  • event-channel delivery from native code to Dart
  • notification-open routing callbacks
  • Android manifest merge behavior
  • manual Firebase FCM and Mattermost ACK smoke testing

Product-specific UI, authentication flows, and navigation should stay in consuming apps. This app should only include the minimum surface needed to prove that the plugin works in isolation.

Structure

example/
  lib/                    # Small harness UI
  test/                   # Widget tests for the harness
  integration_test/       # Device/emulator plugin integration tests
  android/                # Android app used to host the plugin
  ios/                    # iOS host scaffold
  macos/                  # macOS host scaffold

Running The App

Install dependencies:

flutter pub get

Run on a connected device or emulator:

flutter run

For Android FCM smoke testing, make sure the Android app has the required Firebase configuration, including android/app/google-services.json.

Verification

Run checks from this directory:

flutter analyze
flutter test
flutter test integration_test

Run Android native unit tests from example/android:

./gradlew testDebugUnitTest

Android Gradle tests require a configured Android SDK through ANDROID_HOME or example/android/local.properties.

Maintenance Rules

  • Keep the app thin.
  • Prefer deterministic test controls over product-like UI.
  • Do not add consuming-app business logic here.
  • Add integration tests here when a plugin behavior needs a real Flutter host.
  • Keep manual FCM and Mattermost server checks documented in the root README.