mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-19 09:42:21 +00:00
Read "from the map" after any switch or clear verb, before anything else
"clear everything except flights from the map" and "hide everything from the map" now read as they do without the ending, instead of only offering Ask GEV or a place search. Co-authored-by: Manjunath Paparaju <[email protected]>
This commit is contained in:
1 parent
81192cfa50
commit
cd5a4443a2
4 files changed
+27
-14
No files matched your search
@@ -805,12 +805,24 @@ test('"except" leaves Satellites to switch off with Space Missions off', () => {
|
||||
.rows[0].steps.map(stepOutcome),
|
||||
['layer(flights,off)', 'layer(satellites,off)'],
|
||||
);
|
||||
assert.deepEqual(
|
||||
omnibar
|
||||
.rows('hide everything except flights from the map', { places: [] })
|
||||
.rows[0].steps.map(stepOutcome),
|
||||
['layer(satellites,off)'],
|
||||
);
|
||||
for (const text of [
|
||||
'hide everything except flights from the map',
|
||||
'clear everything except flights from the map',
|
||||
])
|
||||
assert.deepEqual(
|
||||
omnibar.rows(text, { places: [] }).rows[0].steps.map(stepOutcome),
|
||||
['layer(satellites,off)'],
|
||||
text,
|
||||
);
|
||||
// The whole map cleared "from the map" is the same plan, not a place.
|
||||
for (const text of [
|
||||
'hide everything from the map',
|
||||
'remove all layers from the map',
|
||||
]) {
|
||||
const { rows } = omnibar.rows(text, { places: [] });
|
||||
assert.equal(rows[0].kind, 'plan', text);
|
||||
assert.ok(!rows.some((row) => row.kind === 'place'), text);
|
||||
}
|
||||
});
|
||||
|
||||
test('"turn off the screen" is no layer switch and no place', () => {
|
||||
|
||||
Reference in new issue
Block a user