mirror of
https://github.com/jonasbark/swiftcontrol.git
synced 2026-11-29 09:11:17 +01:00
Strappo (getstrappo.com) integrates the open OpenBikeControl protocol, so it joins the supported-apps list as an official network/BLE partner (obpMdns + obpBle) — button events arrive over the protocol, so no keyboard keymap is needed. Adds the SupportedApp definition, registry entry, partner logo asset, and a registration test. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
29 lines
1.0 KiB
Dart
29 lines
1.0 KiB
Dart
import 'package:bike_control/utils/keymap/apps/supported_app.dart';
|
|
import 'package:flutter_test/flutter_test.dart';
|
|
|
|
void main() {
|
|
SupportedApp strappo() =>
|
|
SupportedApp.supportedApps.firstWhere((app) => app.name == 'Strappo');
|
|
|
|
test('Strappo is registered as an official supported app', () {
|
|
final matches =
|
|
SupportedApp.supportedApps.where((app) => app.name == 'Strappo');
|
|
expect(matches, hasLength(1));
|
|
expect(matches.first.officialIntegration, isTrue);
|
|
});
|
|
|
|
test('Strappo connects via the OpenBikeControl protocol (mDNS + BLE)', () {
|
|
final app = strappo();
|
|
expect(app.supportLevel(AppConnectionMethod.obpMdns),
|
|
ConnectionSupport.supported);
|
|
expect(app.supportLevel(AppConnectionMethod.obpBle),
|
|
ConnectionSupport.supported);
|
|
// OBC delivers button events over the protocol, so there is no keyboard map.
|
|
expect(app.keymap.keyPairs, isEmpty);
|
|
});
|
|
|
|
test('Strappo ships an official partner logo asset', () {
|
|
expect(strappo().logoAsset, 'assets/strappo.png');
|
|
});
|
|
}
|