More LibreOffice work.
This commit is contained in:
1 parent
4ac59d4ced
commit
b5a5b86dda
15 files changed
+768
-28
No files matched your search
@@ -83,7 +83,7 @@ func TestNativeLibreOfficeCalc(t *testing.T) {
|
||||
if strings.Contains(got, "1048576") || strings.Contains(got, "grayed") {
|
||||
t.Fatalf("Calc capacity/state chatter: %q", got)
|
||||
}
|
||||
if got == want {
|
||||
if got == want || strings.HasSuffix(got, ". "+want) {
|
||||
return
|
||||
}
|
||||
case <-timeout.C:
|
||||
@@ -198,4 +198,52 @@ func TestNativeLibreOfficeCalc(t *testing.T) {
|
||||
waitSpeech("blank, C1")
|
||||
commands <- input.PresentCellFormula
|
||||
waitSpeech("empty")
|
||||
press("ctrl+Home")
|
||||
waitSpeech("Gamma, A1")
|
||||
press("shift+Right")
|
||||
waitSpeech("Cell B1 selected.")
|
||||
press("shift+Down")
|
||||
waitSpeech("Cells A2 to B2 selected.")
|
||||
press("shift+Up")
|
||||
waitSpeech("Cells A2 to B2 unselected.")
|
||||
// Formula commands must still use the active cell, not the range's
|
||||
// first selected child or the sheet that emitted the selection event.
|
||||
commands <- input.PresentCellFormula
|
||||
waitSpeech("Gamma")
|
||||
press("Right")
|
||||
waitSpeech("Selection cleared.")
|
||||
press("ctrl+Home", "shift+space")
|
||||
waitSpeech("Row 1 selected.")
|
||||
press("shift+Down")
|
||||
waitSpeech("Row 2 selected.")
|
||||
press("ctrl+Home", "ctrl+space")
|
||||
waitSpeech("Column A selected.")
|
||||
press("shift+Right")
|
||||
waitSpeech("Column B selected.")
|
||||
press("ctrl+Home", "ctrl+a", "ctrl+a")
|
||||
waitSpeech("All cells selected.")
|
||||
// Calc omits events while shrinking full-column ranges. Growing the
|
||||
// shrunken selection again supplies an event for a capped partial sheet.
|
||||
press("shift+Left", "shift+Left", "shift+Right")
|
||||
waitSpeech("At least 2147483647 cells selected.")
|
||||
press("Right")
|
||||
waitSpeech("Selection cleared.")
|
||||
press("Down")
|
||||
waitSpeech("blank, B2")
|
||||
// Use the provider's selection API to make actual disjoint selections;
|
||||
// these are distinct from the synthetic event/presentation unit checks.
|
||||
if output, err := exec.CommandContext(ctx, "/usr/bin/python3", "../../tests/native_libreoffice.py", "--select-disjoint").CombinedOutput(); err != nil {
|
||||
t.Fatalf("disjoint Calc selection: %v: %s", err, output)
|
||||
}
|
||||
waitSpeech("Cell C1 selected.")
|
||||
commands <- input.PresentCellFormula
|
||||
waitSpeech("empty")
|
||||
press("Right")
|
||||
waitSpeech("Selection cleared.")
|
||||
// A large non-column selection has an exact count, without enumerating
|
||||
// its cells or inferring a rectangle from boundary samples.
|
||||
press("ctrl+Home", "shift+Right", "ctrl+shift+Down", "shift+Up")
|
||||
waitSpeech("2097150 cells selected.")
|
||||
press("Right")
|
||||
waitSpeech("Selection cleared.")
|
||||
}
|
||||
Reference in new issue
Block a user