Add TypeScript integrations package

This commit is contained in:
2026-05-05 12:01:30 +00:00
commit e91176fb9b
5889 changed files with 53433 additions and 0 deletions
+18
View File
@@ -0,0 +1,18 @@
import { expect, tap } from '@git.zone/tstest/tapbundle';
import { createHueDiscoveryDescriptor } from '../../ts/integrations/hue/index.js';
tap.test('matches Hue mDNS records', async () => {
const descriptor = createHueDiscoveryDescriptor();
const matcher = descriptor.getMatchers()[0];
const result = await matcher.matches({
host: 'hue.local',
port: 443,
txt: {
bridgeid: '001788fffe123456',
},
}, {});
expect(result.matched).toBeTrue();
expect(result.normalizedDeviceId).toEqual('001788fffe123456');
});
export default tap.start();