Skip to content

Commit

Permalink
tests: adding a test for resolving the architecture ’all’
Browse files Browse the repository at this point in the history
  • Loading branch information
BLKKKBVSIK committed Dec 29, 2023
1 parent 752f588 commit 61cdeb7
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions packages/app_center/test/packagekit_service_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,29 @@ void main() {
final info = await packageKit.resolve('foo', 'amd64');
expect(info!.packageId.arch, equals('amd64'));
});

test('architecture \'all\'', () async {
final mockTransaction = createMockPackageKitTransaction(
events: const [
PackageKitPackageEvent(
info: PackageKitInfo.available,
packageId: PackageKitPackageId(
name: 'foo',
version: '1.0',
arch: 'all',
),
summary: 'summary',
),
],
);
final mockClient =
createMockPackageKitClient(transaction: mockTransaction);
final packageKit =
PackageKitService(dbus: createMockDbusClient(), client: mockClient);
await packageKit.activateService();
final info = await packageKit.resolve('foo', 'all');
expect(info!.packageId.arch, equals('all'));
});
});

test('cancel', () async {
Expand Down

0 comments on commit 61cdeb7

Please sign in to comment.