Вы находитесь на странице: 1из 9

Test Suite for Mobile Trackpad

White Box Testing


White box tests are implemented using the test automation tools JUnit and Pytest.

Command Class on Android


Test ID Description Expected Result Actual Result

1 Move mouse command Serializing move mouse As expected


command will return byte 0

2 Left click command Serializing left click command will As expected


return byte 1

3 Right click command Serializing right click command As expected


will return byte 2

4 Type character command Serializing type character As expected


command will return byte 3

5 Scroll up command Serializing scroll up command will As expected


return byte 4

6 Scroll down command Serializing scroll down command As expected


will return byte 5

7 Page forward command Serializing page forward As expected


command will return byte 6

8 Page back command Serializing page back command As expected


will return byte 7

9 Zoom in command Serializing zoom in command will As expected


return byte 8

10 Zoom out command Serializing zoom out command As expected


will return byte 9

11 Volume up command Serializing volume up command As expected


will return byte 10

12 Volume down command Serializing volume down As expected


command will return byte 11

13 Volume mute command Serializing command will return As expected


byte 12

14 Volume set command Serializing volume set command As expected


will return byte 13

15 Open browser Serializing open browser As expected


command will return byte 14

16 Open calculator Serializing open calculator As expected


command will return byte 15

17 Refresh command Serializing refresh command will As expected


return byte 16

18 Copy command Serializing copy command will As expected


return byte 17

19 Paste command Serializing paste command will As expected


return byte 18

20 Media play command Serializing media play command As expected


will return byte 19

21 Media pause command Serializing media pause As expected


command will return byte 20

22 Media next track command Serializing media next track As expected


command will return byte 21

23 Media previous track Serializing media previous track As expected


command command will return byte 22

24 Escape command Serializing escape command will As expected


return byte 23

25 Screenshot command Serializing screenshot command As expected


will return byte 24

26 Print command Serializing print command will As expected


return byte 25

27 Save command Serializing save command will As expected


return byte 26

28 Unknown command Serializing unknown command As expected


will return byte 27

29 One argument to command Serializing arguments to As expected


command will return the
arguments as bytes following the
command byte (e.g. command
scroll with arguments 30 will
return bytes 0, 30)

30 Two arguments to commands Serializing arguments to As expected


command will return the
arguments as bytes following the
command byte (e.g. command
move mouse with arguments 5
and 10 will return bytes 0, 5, 10)
Encryptor Class on Android

Test ID Description Expected Result Actual Result

1 Generating public key returns Valid RSA public key generated As expected
a valid RSA public key

2 Generating private key returns Valid RSA private key generated As expected
a valid RSA private key

3 Encryption of message with Encrypted message created As expected


public key

4 Decryption of message with Encrypted message can be As expected


private key decrypted with private key

5 Encrypted message that has Error when decrypting corrupted As expected


been corrupted cannot be encrypted message
decrypted

6 Encrypted message cannot be Error when trying to decrypt As expected


decrypted with incorrect message with wrong private key
private key

Phrase Matcher Class on Android

Test ID Description Expected Result Actual Result

1 Increase volume command The string “increase the volume” As expected


will generate a volume increase
command

2 Decrease volume command The string “volume lower” will As expected


generate a decrease volume
command

3 Mute volume command The string “turn off sound” will As expected
generate a volume mute
command

4 Set volume command The string “set volume to 75” will As expected
generate a volume set
command

5 Open web browser command The string “start google chrome” As expected
will generate an open web
browser command

6 Open calculator command The string “open calculator” will As expected


generate an open calculator
command

7 Copy command The string “copy selection to As expected


clipboard” will generate a
command
8 Paste command The string “paste from clipboard” As expected
will generate a paste command

9 Escape command The string “escape” will As expected


generate an escape command

10 Media next track command The string “next track” will As expected
generate a media next track
command

11 Media previous track The string “previous media” will As expected


command generate a media previous track
command

12 Media pause command The string “stop current media” As expected


will generate a media pause
command

13 Media play command The string “start current song” As expected


will generate a media play
command

14 Save command The string “save current file” will As expected


generate a save command

15 Screenshot command The string “take screenshot will As expected


generate a screenshot
command

16 Print command The string “print current As expected


document” will generate a print
command

17 Unknown command The string “make sandwich” will As expected


generate an unknown command

18 Vague command The string “volume” will As expected


generate an unknown command

19 Missing parameter The string “set volume to” will As expected


generate an unknown command

20 Multiple commands The string “raise lower volume” As expected


will generate an unknown
command

21 Punctuation The string “copy to clipboard?!” As expected


will generate a copy command

22 All caps The string “PLAY MEDIA” will As expected


generate a media play
command
Black Box Testing
Black box tests are performed manually by a quality assurance tester. They require the Mobile
Trackpad app to be running on the Android smartphone, and the Python server application to be
running on the computer. The instructions for running the app are found in the README.md file
in the root project directory.

Trackpad Mouse Control


Test ID Description Expected Result Actual Result

1 Move mouse System must respond to As expected


single-touch movements on the
smartphone by moving the
mouse an equivalent amount on
the computer screen

2 Left click command A single tap without movement As expected


will cause the system to deliver a
click event to the computer’s
foreground application

3 Right click command A two-finger tap without As expected


movement will cause the system
to deliver a right-click event to the
computer’s foreground
application

4 Three taps A three finger tap should not Page forward and right click
cause the system to execute commands generated
anything

5 Mouse Sensitivity The user can control the trackpad As expected


sensitivity from the settings
menu. A higher sensitivity will
make finger movements on the
smartphone correspond to faster
movements on the computer
mouse.

Keyboard Inputs
Test ID Description Expected Result Actual Result

1 Keyboard input In keyboard mode, the system As expected


must respond to each typed
character by sending the
character to the computer’s
foreground application.

2 Glide typing In keyboard mode, if full words As expected


are entered at once (for example,
on a glide-based keyboard), the
system must respond by typing
each character in order to the
computer’s foreground
application.

3 Character functionality The system should be able to As expected


type onto the computer all
characters supported by the
smartphone’s native keyboard

4 Order of text Quickly typed input on the As expected


smartphone should be typed in
the correct order to the computer

5 Backspace Typing backspace on the phone As expected


should execute a backspace key
on the computer

Command Linked Gestures


Test ID Description Expected Result Actual Result

1 Scroll up The user performs a two-finger Swipe up causes scroll down


swipe up and the system delivers
a scroll-up event to the computer.

2 Scroll down The user performs a two-finger Swipe down causes scroll up
swipe down and the system
delivers a scroll-down event to
the computer.

3 Page back The user performs a two-finger As expected


swipe left and the system delivers
a “page back” event to the
computer.

4 Page forward The user performs a two-finger As expected


swipe right and the system
delivers a “page-forward” event to
the computer.

5 Zoom in The user performs a two-finger As expected


pinch gesture outwards and the
system delivers a “zoom-in” event
to the computer

6 Zoom out The user performs a two-finger As expected


pinch gesture inwards and the
system delivers a “zoom-out”
event to the computer

7 Gesture do not affect mouse In trackpad mode, the system As expected


must not move the mouse in
response to a multiple touch
input.
Pairing
Test ID Description Expected Result Actual Result

1 View nearby devices If a computer and smartphone Works on most wireless


are on the same wireless networks. However, on some
network, the phone must be able networks, such as the
to see the name of the computer. University of Alberta’s Wi-Fi
network, devices are
prevented from seeing each
other.

2 Verification code Once the phone starts the pairing As expected


process by tapping the name of
the computer in the pairing menu,
the phone will display a random
six-digit number, which the user
must type into the computer (the
user will be prompted to type this
number). If the number is correct,
the pairing process is complete.

3 Incorrect verification code If the incorrect six-digit number is As expected


entered into the computer during
the pairing process, the pairing
must not succeed.

4 Automatic pairing Once a smartphone is paired with As expected


the computer, the computer and
smartphone will remember each
other. On subsequent pairings,
no number entry will be required.

5 Saved devices A phone may remember multiple As expected


computers it has already paired
with, and a computer may
remember multiple phones it has
already paired with.

6 Remove saved device If the computer revokes the Not implemented


phone’s access to the computer,
the next pairing will again require
the six-digit number entry
sequence.

Smartphone User Interface


Test ID Description Expected Result Actual Result

1 Open keyboard In trackpad mode, the system As expected


must respond to the “Open
Keyboard” command by
displaying the smartphone’s
native keyboard to the user.

2 Open Menu In trackpad mode, the system As expected


must respond to the “Open
Menu” command by displaying
the application menu to the user.

3 Open both menu and In trackpad mode, the system As expected


keyboard should support opening both the
keyboard and menu at the same
time

4 Trackpad area In trackpad mode, the system will As expected


display a trackpad area over the
majority of the screen.

5 Trackpad buttons In trackpad mode, the system will As expected


display a sidebar with three
buttons for activating keyboard
mode, opening the settings
menu, and activating voice
command listening.

Disconnect button In the settings menu, the user will As expected


be able to disconnect from the
currently paired computer.

About us and privacy policy In the settings menu, the user will As expected
be able to view the “about us”
section and privacy policy.

Port number change In the settings menu, the use will Not implemented
be able to change the port
number that the app uses to try to
connect to a computer.

Adaptive resizing The smartphone user interface As expected


must adapt to different screen
sizes

Computer User Interface


Test ID Description Expected Result Actual Result

App icon in system tray The app will be in the operating As expected
system’s system tray.

Display connected When the computer’s cursor Not implemented


smartphone clicks the app’s icon, the current
connected device, if any, is
displayed.

Settings menu When the app’s icon in the Not implemented


system tray is double clicked, the
settings menu for the app is
displayed.

View saved connections The settings menu will have Not implemented
options to view saved
connections, and configuration.
Remove saved devices The saved connections submenu Not implemented
will allow the removal of saved
devices.

Configure settings The configuration menu will have Not implemented


options to configure the
automatic startup of the app as
well as the port number that the
app uses to listen for requests
from the paired/pairing
smartphone.

Вам также может понравиться