mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-16 08:12:24 +00:00
fix(voice): resolve follow-up review edge cases
This commit is contained in:
1 parent
1594db9497
commit
b5cb75bcf9
13 files changed
+232
-16
No files matched your search
@@ -1,5 +1,6 @@
|
||||
import assert from 'node:assert/strict';
|
||||
import test from 'node:test';
|
||||
import { attachVoiceResult } from './speech.js';
|
||||
import { resolveDeicticArgs } from './deixis.js';
|
||||
import { createReferentRegistry, referentsFromResult } from './referents.js';
|
||||
|
||||
@@ -167,3 +168,15 @@ test('registry: hidden card rows never resolve and last means displayed item fiv
|
||||
assert.equal(referents.get(6), null);
|
||||
assert.equal(referents.get(-1)?.id, 'F5');
|
||||
});
|
||||
|
||||
|
||||
test('numbered custom-labeled pins retain their resolved coordinates', () => {
|
||||
const referents = createReferentRegistry();
|
||||
const result = attachVoiceResult('annotate_map', {
|
||||
ok: true,
|
||||
items: [{ ok: true, id: 'pin-1', label: 'Meeting point', latitude: 30.27, longitude: -97.74 }],
|
||||
});
|
||||
referents.recordResult('annotate_map', result);
|
||||
assert.deepEqual(resolveDeicticArgs('fly_to_location', { referent: 1 }, { referents }).args,
|
||||
{ latitude: 30.27, longitude: -97.74 });
|
||||
});
|
||||
Reference in new issue
Block a user