mirror of
https://github.com/priyanshujain/sanderling.git
synced 2026-10-04 12:07:09 +00:00
refactor(spec): picker emits native selector + scroll endpoints, setup precedence
This commit is contained in:
1 parent
6600994ef1
commit
7a5fc9aca5
5 files changed
+161
-12
No files matched your search
@@ -53,7 +53,11 @@ test("taps draws one candidate index and targets its point", () => {
|
||||
const action = walk(builtin("taps"), rng, host);
|
||||
assert.deepEqual(action, {
|
||||
kind: "Tap",
|
||||
on: { x: POINTS[expectedIndex]!.x, y: POINTS[expectedIndex]!.y },
|
||||
on: {
|
||||
x: POINTS[expectedIndex]!.x,
|
||||
y: POINTS[expectedIndex]!.y,
|
||||
selector: POINTS[expectedIndex]!.selector,
|
||||
},
|
||||
});
|
||||
});
|
||||
|
||||
@@ -72,6 +76,7 @@ test("typing draws candidate index then corpus index, in that order", () => {
|
||||
assert.deepEqual(action.into, {
|
||||
x: POINTS[candidateIndex]!.x,
|
||||
y: POINTS[candidateIndex]!.y,
|
||||
selector: POINTS[candidateIndex]!.selector,
|
||||
});
|
||||
assert.equal(action.text, INPUT_CORPUS[corpusIndex]);
|
||||
});
|
||||
@@ -142,7 +147,11 @@ test("doubleTaps and longPresses draw exactly one candidate index", () => {
|
||||
const kind = verb === "doubleTaps" ? "DoubleTap" : "LongPress";
|
||||
assert.deepEqual(action, {
|
||||
kind,
|
||||
on: { x: POINTS[index]!.x, y: POINTS[index]!.y },
|
||||
on: {
|
||||
x: POINTS[index]!.x,
|
||||
y: POINTS[index]!.y,
|
||||
selector: POINTS[index]!.selector,
|
||||
},
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user