support/testing/tests/package/test_flutter.py: use flutter-markdown-example

The maintainers of the flutter-gallery package archived the project as of
February 16, 2024. In addition, the flutter-gallery package is incompatible
with Flutter 3.19.x. Because of these problems, using the flutter-gallery
package as the testing application for Flutter is no longer reasonable nor
maintainable.

However, it is reasonable to use the flutter-markdown-example package from
flutter-packages, as it is a first-party application updated regularly and
often automatically, ensuring compatibility with the latest versions of
Flutter.

  - Switch the package used for Flutter testing from flutter-gallery to
    flutter-markdown-example

  - Rename flutter-gallery.service to flutter-markdown-example.service

  - Change /usr/share/flutter/gallery/release/ to
    /usr/share/flutter/flutter_markdown_example/release/

  - Run `systemctl is-active flutter-markdown-example` instead of
   `systemctl is-active flutter-gallery`

Signed-off-by: Adam Duskett <adam.duskett@amarulasolutions.com>
Signed-off-by: Arnout Vandecappelle <arnout@mind.be>
This commit is contained in:
Adam Duskett 2024-03-25 16:34:19 -06:00 committed by Arnout Vandecappelle
parent c51e0f4aec
commit a92e7c3cec
5 changed files with 15 additions and 14 deletions

View File

@ -25,7 +25,8 @@ class TestFlutter(infra.basetest.BRTest):
BR2_PACKAGE_FLUTTER_PI=y
BR2_PACKAGE_FLUTTER_PI_RAW_KEYBOARD_PLUGIN=y
BR2_PACKAGE_FLUTTER_PI_TEXT_INPUT_PLUGIN=y
BR2_PACKAGE_FLUTTER_GALLERY=y
BR2_PACKAGE_FLUTTER_PACKAGES=y
BR2_PACKAGE_FLUTTER_MARKDOWN_EXAMPLE=y
BR2_PACKAGE_FLUTTER_ENGINE=y
BR2_TARGET_ROOTFS_EXT2=y
BR2_TARGET_ROOTFS_EXT2_4=y
@ -48,7 +49,7 @@ class TestFlutter(infra.basetest.BRTest):
"-vnc", "none",
"-drive", f"file={img},if=virtio,format=raw"])
self.emulator.login()
cmd = "systemctl is-active flutter-gallery"
cmd = "systemctl is-active flutter-markdown-example"
output, exit_code = self.emulator.run(cmd, 10)
self.assertEqual(exit_code, 0)
self.assertEqual(output[0], "active")

View File

@ -1 +0,0 @@
../../../../usr/lib/systemd/system/flutter-gallery.service

View File

@ -0,0 +1 @@
../../../../usr/lib/systemd/system/flutter-markdown-example.service

View File

@ -1,11 +0,0 @@
[Unit]
Description=flutter-gallery daemon
After=dbus.service systemd-udevd.service
[Service]
ExecStart=/usr/bin/flutter-pi --release /usr/share/flutter/gallery/release/
Restart=always
KillMode=process
[Install]
WantedBy=multi-user.target

View File

@ -0,0 +1,11 @@
[Unit]
Description=flutter-markdown-example daemon
After=dbus.service systemd-udevd.service
[Service]
ExecStart=/usr/bin/flutter-pi --release /usr/share/flutter/flutter_markdown_example/release/
Restart=always
KillMode=process
[Install]
WantedBy=multi-user.target