예제 #1
0
#!/usr/bin/python

from macaroon.playback import *
import utils

utils.setClipboardText("Hello world")

sequence = MacroSequence()
sequence.append(PauseAction(3000))
sequence.append(KeyComboAction("Return"))
sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("<Control><Shift>v"))
sequence.append(
    utils.AssertPresentationAction("1. Paste", [
        "BRAILLE LINE:  '$ Hello world'",
        "     VISIBLE:  '$ Hello world', cursor=14",
        "BRAILLE LINE:  'Pasted contents from clipboard.'",
        "     VISIBLE:  'Pasted contents from clipboard.', cursor=0",
        "BRAILLE LINE:  '$ Hello world'",
        "     VISIBLE:  '$ Hello world', cursor=14",
        "SPEECH OUTPUT: 'Pasted contents from clipboard.' voice=system"
    ]))

sequence.append(utils.AssertionSummaryAction())
sequence.start()
예제 #2
0
파일: pasting.py 프로젝트: GNOME/orca
#!/usr/bin/python

from macaroon.playback import *
import utils

utils.setClipboardText("Hello world")

sequence = MacroSequence()
sequence.append(PauseAction(3000))
sequence.append(KeyComboAction("Return"))
sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("<Control><Shift>v"))
sequence.append(utils.AssertPresentationAction(
    "1. Paste",
    ["BRAILLE LINE:  '$ Hello world'",
     "     VISIBLE:  '$ Hello world', cursor=14",
     "BRAILLE LINE:  'Pasted contents from clipboard.'",
     "     VISIBLE:  'Pasted contents from clipboard.', cursor=0",
     "BRAILLE LINE:  '$ Hello world'",
     "     VISIBLE:  '$ Hello world', cursor=14",
     "SPEECH OUTPUT: 'Pasted contents from clipboard.' voice=system"]))

sequence.append(utils.AssertionSummaryAction())
sequence.start()
예제 #3
0
#!/usr/bin/python

from macaroon.playback import *
import utils

utils.setClipboardText('for i in {0..50}; do echo "Count: $i"; sleep 2;  done')

sequence = MacroSequence()
sequence.append(KeyComboAction("<Control><Shift>v"))
sequence.append(KeyComboAction("Return"))

sequence.append(KeyComboAction("<Control><Shift>t"))

sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("Return"))
sequence.append(PauseAction(2000))
sequence.append(
    utils.AssertPresentationAction("1. Return", [
        "BRAILLE LINE:  '$ '", "     VISIBLE:  '$ ', cursor=3",
        "SPEECH OUTPUT: '$ '"
    ]))

sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("Return"))
sequence.append(PauseAction(2000))
sequence.append(
    utils.AssertPresentationAction("2. Return", [
        "BRAILLE LINE:  '$ '", "     VISIBLE:  '$ ', cursor=3",
        "SPEECH OUTPUT: '$ '"
    ]))
예제 #4
0
#!/usr/bin/python

from macaroon.playback import *
import utils

utils.setClipboardText('for i in {0..50}; do echo "Count: $i"; sleep 2;  done')

sequence = MacroSequence()
sequence.append(KeyComboAction("<Control><Shift>v"))
sequence.append(KeyComboAction("Return"))

sequence.append(KeyComboAction("<Control><Shift>t"))

sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("Return"))
sequence.append(PauseAction(2000))
sequence.append(utils.AssertPresentationAction(
    "1. Return",
    ["BRAILLE LINE:  '$ '",
     "     VISIBLE:  '$ ', cursor=3",
     "SPEECH OUTPUT: '$ '"]))

sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("Return"))
sequence.append(PauseAction(2000))
sequence.append(utils.AssertPresentationAction(
    "2. Return",
    ["BRAILLE LINE:  '$ '",
     "     VISIBLE:  '$ ', cursor=3",
     "SPEECH OUTPUT: '$ '"]))
예제 #5
0
#!/usr/bin/python

from macaroon.playback import *
import utils

utils.setClipboardText('PS1="prompt> "')

sequence = MacroSequence()

sequence.append(PauseAction(3000))

sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("Return"))
sequence.append(utils.AssertPresentationAction(
    "1. Return in old shell",
    ["BRAILLE LINE:  '$ '",
     "     VISIBLE:  '$ ', cursor=3",
     "SPEECH OUTPUT: '$ '"]))

sequence.append(TypeAction("bash"))
sequence.append(KeyComboAction("Return"))
sequence.append(utils.StartRecordingAction())

sequence.append(KeyComboAction("<Control><Shift>v"))
sequence.append(KeyComboAction("Return"))

sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("Return"))
sequence.append(utils.AssertPresentationAction(
    "2. Return in new shell with changed prompt",
    ["BRAILLE LINE:  'prompt> '",
예제 #6
0
파일: exit_shell.py 프로젝트: GNOME/orca
#!/usr/bin/python

from macaroon.playback import *
import utils

utils.setClipboardText('PS1="prompt> "')

sequence = MacroSequence()

sequence.append(PauseAction(3000))

sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("Return"))
sequence.append(
    utils.AssertPresentationAction(
        "1. Return in old shell", ["BRAILLE LINE:  '$ '", "     VISIBLE:  '$ ', cursor=3", "SPEECH OUTPUT: '$ '"]
    )
)

sequence.append(TypeAction("bash"))
sequence.append(KeyComboAction("Return"))
sequence.append(utils.StartRecordingAction())

sequence.append(KeyComboAction("<Control><Shift>v"))
sequence.append(KeyComboAction("Return"))

sequence.append(utils.StartRecordingAction())
sequence.append(KeyComboAction("Return"))
sequence.append(
    utils.AssertPresentationAction(
        "2. Return in new shell with changed prompt",