Last Modified: July 22nd, 1998
This document contains the test plan for verifying the TargetRTS debugger Table of Contents: 1. Introduction 2. TargetRTS configuration 3. TargetRTS debugger command list 4. Testing of configuration without the debugger 5. Testing of configuration with the debugger
This document provides the test plan for the TargetRTS debugger. It could be used to test any platform supporting the debugger. The purpose of this test plan is to verify that all known features of the debugger are working properly. Command parameters and order of test cases: For each test case, a suggested command and parameter is given. If you change the order of the test cases, you might not get the expected results. The results will have to be analysed according to the new sequence of operations.
There are currently three (2) TargetRTS possible configurations for the debugger which are RSLDEBUG = RSLFALSE : Minimum executable size, no debugger RSLDEBUG = RSLTRUE : Maximum debugging (default) The selection of the wanted configuration is done by editing the file "RTConfig.h" The TargetRTS must be rebuilt and will reflect the change. Update used for the following tests: C_DebuggingExample
cont Continue execution. delete <n> Delete trace point <n>. detach Don't pay attention to <tasksId>. exit Terminate process. go [<n>] Deliver <n> messages (default is 10). help Print help information. info <actor> Show information about actor. list List all trace points. log <detail-level> Log ROOM messages detail levels: none all printstats <n> Print current statistics for task <n>. quit Quit debug mode. saps Show registered SPPs and corresponding SAPs. stats <n> Alias for printstats. step [<n>] Deliver <n> messages (default is 1). system List all the active actors in the system. trace <actor> <type= endport | relayport | sap | spp> <port> Trace messages involving port. Unambiguous abbreviations are permitted for all commands.
This configuration is the one without the debugger. The following applies: Test case 1: Verify that the size of the executable is smaller than "with" debugger version of the executable file. Test case 2: Using unix commands such as "strings" or "hd" and "grep", search for the string "RTS debug" in the executable file. The absence of this string confirms that the debugger was not linked. Test case 3: Run the executable. Enter "q" followed by enter. It should loop indefinitely after displaying: *** Warning: Actor kibitz/Kibitz[5] sending signal Synchronization[2] data 0x0 on port Cheater[9->?] UNBOUND! *** Warning: Actor kibitz/Kibitz[5] sending signal Synchronization[2] data 0x0 on port Cheater[10->?] UNBOUND! *** Warning: Actor kibitz/Kibitz[5] sending signal Synchronization[2] data 0x0 on port Cheater[11->?] UNBOUND! Should it exit immediately, it means there is a problem.
This configuration is the one with maximum debug information. The executable is invoked on the target and the following test cases are applied. To run these tests, you must first run the executable which will show the debugger prompt such as: ObjecTime C Target Run Time System Release 5.20 Copyright © 1993-1998 ObjecTime Limited RTS debug: -> Starting without a TO connection Testing of informational commands: Test case 4: enter: "step" expected output: step 1 *** Warning: Actor kibitz/Kibitz[5] sending signal Synchronization[2] data 0x0 on port Cheater[9->?] UNBOUND! *** Warning: Actor kibitz/Kibitz[5] sending signal Synchronization[2] data 0x0 on port Cheater[10->?] UNBOUND! *** Warning: Actor kibitz/Kibitz[5] sending signal Synchronization[2] data 0x0 on port Cheater[11->?] UNBOUND! enter: "step" expected output: step 1 enter: "go 3" expected output: go 3 enter: "saps" expected output: SPP TheCheater: 3 SAPs Pass criteria: You should see the registered SAPS (3 in the case of our model) Test case 5: enter: "system" expected output: TopActor : TopActor(fixed) 0 . server : Server(fixed) 1 . client : Client(fixed) 2 . client : Client(fixed) 3 . client : Client(fixed) 4 . kibitz : Kibitz(fixed) 5 Pass criteria: you should see the current status of the model. Verify that you see the proper strings which consists of <refName>:<className> (< type = fixed >) <actorId> for each actor Test case 6: enter: "info 2" expected output: ClassName : Client ReferenceName : client CurrentState : Awake Address : (Client_InstanceData*)0x37298 <- Address might be different No Actor Probe attached. End ports: 0: clientServerComm SAPs: 0: Cheater registered as 'TheCheater' Pass criteria: this command should list info about a particular actor. Invoke it using the actorId (see system) as a parameter and verify that the printed strings are relevant Test case 7: enter: "stats 0" or "printstats 0" expected output: Thread 0 messages[System] : 0 messages[Panic] : 0 messages[High] : 0 messages[General] : 3 messages[Low] : 0 messages[Background] : 0 messages[incoming] : 0 messages[freeGlobal] : 97 messages[freeTCBs] : 10 messages[activeTCBs] : 0 Pass criteria: Should normally list 3 General messages if the previous test cases were run properly. Both stats and printstats should be tested. Testing of control commands: Testing of tracing commands: (The control and tracing commands are tested concurrently since we need some form of feedback as to confirm the working of a control command) Initial setting: Turn the full logging by entering command enter: "log all" expected output: (debug prompt only) Test case 8: enter: "step" expected output: step 1 General message to client(Client)<WaitForSynch>.System[0]:hello from server(Server)<S1>.clientServerComm[1] data (void *)0(0x0) General message to server(Server)<top>.System[0]:huh from client(Client)<S1>.clientServerComm[1] data (void *)0(0x0) Pass criteria: Should see the above info. Test case 9: enter: "go 3" expected output: go 3 General message to client(Client)<WaitForSynch>.System[0]:hello from server(Server)<S1>.clientServerComm[2] data (void *)0(0x0) General message to server(Server)<S1>.System[0]:huh from client(Client)<WaitForSync>.clientServerComm[1] data (void *)0(0x0) General message to server(Server)<S1>.System[0]:huh from client(Client)<WaitForSync>.clientServerComm[1] data (void *)0(0x0) General message to server(Server)<S1>.System[0]:huh from client(Client)<WaitForSync>.clientServerComm[1] data (void *)0(0x0) General message to client(Client)<Awake>.System[0]:notMe from server(Server)<S1>.clientServerComm[2] data (void *)0(0x0) General message to client(Client)<Awake>.System[0]:notMe from server(Server)<S1>.clientServerComm[2] data (void *)0(0x0) Pass criteria: Should see the messages info such as the ones above. Test case 10: enter: "exit" expected output: None Pass criteria: Should get the operating system prompt Test case 11: (To execute the following you must invoke the executable again from the operating system before you attempt the command if you used the exit of case 10) enter: "quit" expected output: *** Warning: Actor kibitz/Kibitz[5] sending signal Synchronization[2] data 0x0 on port Cheater[9->?] UNBOUND! *** Warning: Actor kibitz/Kibitz[5] sending signal Synchronization[2] data 0x0 on port Cheater[10->?] UNBOUND! *** Warning: Actor kibitz/Kibitz[5] sending signal Synchronization[2] data 0x0 on port Cheater[11->?] UNBOUND! Pass criteria: It should exit immediately after that text output. Should it loop indefinitely, there is a problem. Test case 12: (To execute the following you must invoke the executable again from the operating system before you attempt the command if you used the quit of case 14) enter: "trace 4 end 0" expected output: 0: Port clientServerComm[0] on client : Client 4 enter: "go 20" expected output: go 20 General message to client(Client)<WaitForSynch>.System[0]:hello from server(Server)<S1>.clientServerComm[2] data (void *)0(0x0) General message to server(Server)<S1>.System[0]:huh from client(Client)<WaitForSync>.clientServerComm[2] data (void *)0(0x0) General message to client(Client)<Awake>.System[0]:notMe from server(Server)<S1>.clientServerComm[2] data (void *)0(0x0) Pass criteria: Should see the messages same as above Test case 13: enter: "list" expected output: 0: Port clientServerComm[0] on client : Client 4 Pass criteria: Should have the client actor listed as having a probe Test case 14: enter: "delete 0" (zero not O) expected output: Deleted 0: Port clientServerComm[0] on client : Client 4 enter: "list" expected output: (debug prompt only) Pass criteria: Should not see the probe listed anymore Test case 15: enter: "help" expected output: (see section 3 for expected output) Pass criteria: Should see help text similar to description of section 3 enter: "exit"
to terminate the test