lttng: Fix Javadoc and formatting in lttng2.ui
[deliverable/tracecompass.git] / org.eclipse.linuxtools.lttng2.ui.tests / testfiles / LTTngServiceTest.cfg
CommitLineData
d132bcc7
BH
1####################################################################
2# Copyright (c) 2012 Ericsson
3#
4# All rights reserved. This program and the accompanying materials are
5# made available under the terms of the Eclipse Public License v1.0 which
6# accompanies this distribution, and is available at
7# http://www.eclipse.org/legal/epl-v10.html
8#
9# Contributors:
10# Bernd Hufmann - Initial API and implementation
11####################################################################
12####################################################################
13# Scenario: Test lttng not installed
14####################################################################
15<SCENARIO>
16LttngNotInstalled
17<COMMAND_INPUT>
18lttng list
19</COMMAND_INPUT>
20<COMMAND_RESULT>
211
22</COMMAND_RESULT>
23<COMMAND_OUTPUT>
24Command not found
25</COMMAND_OUTPUT>
26</SCENARIO>
27
276c17e7
BH
28####################################################################
29# Scenario: Test lttng version
30####################################################################
31<SCENARIO>
32LttngVersion
33<COMMAND_INPUT>
34lttng version
35</COMMAND_INPUT>
36<COMMAND_RESULT>
370
38</COMMAND_RESULT>
39<COMMAND_OUTPUT>
40lttng version 2.0.0 - Annedd'ale
41Web site: http://lttng.org/
42
43lttng is free software and under the GPL license and part LGPL
44</COMMAND_OUTPUT>
45</SCENARIO>
46
47####################################################################
48# Scenario: Test lttng version (unsupported version)
49####################################################################
50<SCENARIO>
51LttngUnsupportedVersion
52<COMMAND_INPUT>
53lttng version
54</COMMAND_INPUT>
55<COMMAND_RESULT>
560
57</COMMAND_RESULT>
58<COMMAND_OUTPUT>
59lttng version 200.0.0 - Annedd'ale
60Web site: http://lttng.org/
61
62lttng is free software and under the GPL license and part LGPL
63</COMMAND_OUTPUT>
64</SCENARIO>
65
66
67####################################################################
68# Scenario: Test lttng version (noversion)
69####################################################################
70<SCENARIO>
71LttngNoVersion
72<COMMAND_INPUT>
73lttng version
74</COMMAND_INPUT>
75<COMMAND_RESULT>
760
77</COMMAND_RESULT>
78<COMMAND_OUTPUT>
79Web site: http://lttng.org/
80
81lttng is free software and under the GPL license and part LGPL
82</COMMAND_OUTPUT>
83</SCENARIO>
84
d132bcc7
BH
85####################################################################
86# Scenario: Test no sessions available
87####################################################################
88<SCENARIO>
89NoSessionAvailable
90<COMMAND_INPUT>
91lttng list
92</COMMAND_INPUT>
93<COMMAND_RESULT>
940
95</COMMAND_RESULT>
96<COMMAND_OUTPUT>
97Currently no available tracing session
98</COMMAND_OUTPUT>
99</SCENARIO>
100
101####################################################################
102# Scenario: Test get sessions
103####################################################################
104<SCENARIO>
105GetSessionNames1
106<COMMAND_INPUT>
107lttng list
108</COMMAND_INPUT>
109<COMMAND_RESULT>
1100
111</COMMAND_RESULT>
112<COMMAND_OUTPUT>
113Available tracing sessions:
114 1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928) [inactive]
115 2) mysession (/home/user/lttng-traces/mysession-20120123-083318) [inactive]
116
117 Use lttng list <session_name> for more details
118</COMMAND_OUTPUT>
119</SCENARIO>
120
121####################################################################
122# Scenario: Test lttng list <name> where session doesn't exist
123####################################################################
124<SCENARIO>
125GetSessionNameNotExist
126<COMMAND_INPUT>
127lttng list test
128</COMMAND_INPUT>
129<COMMAND_RESULT>
1301
131</COMMAND_RESULT>
132<COMMAND_OUTPUT>
133Session test not found
134Error: Session name not found
135</COMMAND_OUTPUT>
136</SCENARIO>
137
138####################################################################
139# Scenario: Test lttng list with garbage output
140####################################################################
141<SCENARIO>
142GetSessionGarbageOut
143<COMMAND_INPUT>
144lttng list
145</COMMAND_INPUT>
146<COMMAND_RESULT>
1470
148</COMMAND_RESULT>
149<COMMAND_OUTPUT>
150asdfaereafsdcv 12333456434&*89**(())(^%$*
151@#$%^&*()@#$%^&*()0834523094578kj;djkfs
152a;sdf094v5u dsafj;sd9
153</COMMAND_OUTPUT>
154</SCENARIO>
155
156####################################################################
157# Scenario: Test lttng list <name> with sample outputs
158####################################################################
159<SCENARIO>
160GetSession1
161<COMMAND_INPUT>
162lttng list mysession
163</COMMAND_INPUT>
164<COMMAND_RESULT>
1650
166</COMMAND_RESULT>
167<COMMAND_OUTPUT>
168Tracing session mysession: [active]
169 Trace path: /home/user/lttng-traces/mysession-20120129-084256
170
171=== Domain: Kernel ===
172
173Channels:
174-------------
175- channel0: [enabled]
176
177 Attributes:
178 overwrite mode: 0
179 subbufers size: 262144
180 number of subbufers: 4
181 switch timer interval: 0
182 read timer interval: 200
183 output: splice()
184
185 Events:
186 block_rq_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
187 block_bio_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [disabled]
188
189- channel1: [disabled]
190
191 Attributes:
192 overwrite mode: 1
193 subbufers size: 524288
194 number of subbufers: 4
195 switch timer interval: 100
196 read timer interval: 400
197 output: splice()
198
199 Events:
200 None
201
202=== Domain: UST global ===
203
204Channels:
205-------------
206- mychannel1: [disabled]
207
208 Attributes:
209 overwrite mode: 1
210 subbufers size: 8192
211 number of subbufers: 8
212 switch timer interval: 200
213 read timer interval: 100
214 output: mmap()
215
216 Events:
217 None
218
219- channel0: [enabled]
220
221 Attributes:
222 overwrite mode: 0
223 subbufers size: 4096
224 number of subbufers: 4
225 switch timer interval: 0
226 read timer interval: 200
227 output: mmap()
228
229 Events:
230 ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_LINE (13)) (type: tracepoint) [disabled]
231 * (type: tracepoint) [enabled]
232
233</COMMAND_OUTPUT>
234<COMMAND_INPUT>
235lttng list mysession1
236</COMMAND_INPUT>
237<COMMAND_RESULT>
2380
239</COMMAND_RESULT>
240<COMMAND_OUTPUT>
241Tracing session mysession1: [inactive]
242 Trace path: /home/user/lttng-traces/mysession1-20120203-133225
243
244</COMMAND_OUTPUT>
245</SCENARIO>
246
247
248####################################################################
249# Scenario: Test "lttng list -k" with sample output
250####################################################################
251<SCENARIO>
252GetKernelProvider1
253<COMMAND_INPUT>
254lttng list -k
255</COMMAND_INPUT>
256<COMMAND_RESULT>
2570
258</COMMAND_RESULT>
259<COMMAND_OUTPUT>
260Kernel events
261-------------
262 sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
263 sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
264 sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
265
266</COMMAND_OUTPUT>
267</SCENARIO>
268
269####################################################################
270# Scenario: Test "lttng list -u" with sample output
271####################################################################
272<SCENARIO>
273GetUstProvider1
274<COMMAND_INPUT>
275lttng list -u
276</COMMAND_INPUT>
277<COMMAND_RESULT>
2780
279</COMMAND_RESULT>
280<COMMAND_OUTPUT>
281UST events:
282-------------
283
284PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
285 ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint)
286 ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint)
287
288PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
289 ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
290 ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
291
292</COMMAND_OUTPUT>
293</SCENARIO>
294
295####################################################################
296# Scenario: Test "lttng list -u" with no UST provider available
297####################################################################
298<SCENARIO>
299GetUstProvider2
300<COMMAND_INPUT>
301lttng list -u
302</COMMAND_INPUT>
303<COMMAND_RESULT>
3040
305</COMMAND_RESULT>
306<COMMAND_OUTPUT>
307UST events:
308-------------
309None
310
311</COMMAND_OUTPUT>
312</SCENARIO>
313
314####################################################################
315# Scenario: Test "lttng create <session>
316####################################################################
317<SCENARIO>
318CreateSession1
319<COMMAND_INPUT>
320lttng create mysession2
321</COMMAND_INPUT>
322<COMMAND_RESULT>
3230
324</COMMAND_RESULT>
325<COMMAND_OUTPUT>
326Session mysession2 created.
327Traces will be written in /home/user/lttng-traces/mysession2-20120209-095418
328</COMMAND_OUTPUT>
329</SCENARIO>
330
331####################################################################
332# Scenario: Test "lttng create <session> with different variants
333# and errors
334####################################################################
335<SCENARIO>
336CreateSessionVariants
337<COMMAND_INPUT>
338lttng create alreadyExist
339</COMMAND_INPUT>
340<COMMAND_RESULT>
3411
342</COMMAND_RESULT>
343<COMMAND_OUTPUT>
344Error: Session name already exist
345</COMMAND_OUTPUT>
346
347<COMMAND_INPUT>
348lttng create "session with spaces"
349</COMMAND_INPUT>
350<COMMAND_RESULT>
3510
352</COMMAND_RESULT>
353<COMMAND_OUTPUT>
354Session session with spaces created.
355Traces will be written in /home/user/lttng-traces/session with spaces-20120209-095418
356</COMMAND_OUTPUT>
357
358<COMMAND_INPUT>
359lttng create wrongName
360</COMMAND_INPUT>
361<COMMAND_RESULT>
3620
363</COMMAND_RESULT>
364<COMMAND_OUTPUT>
365Session auto created.
366Traces will be written in /home/user/lttng-traces/auto-20120209-095418
367</COMMAND_OUTPUT>
368
369<COMMAND_INPUT>
370lttng create wrongPath -o /home/user/hallo
371</COMMAND_INPUT>
372<COMMAND_RESULT>
3730
374</COMMAND_RESULT>
375<COMMAND_OUTPUT>
376Session wrongPath created.
377Traces will be written in /home/user/lttng-traces/wrongPath-20120209-095418
378</COMMAND_OUTPUT>
379
380<COMMAND_INPUT>
381lttng create pathWithSpaces -o "/home/user/hallo user/here"
382</COMMAND_INPUT>
383<COMMAND_RESULT>
3840
385</COMMAND_RESULT>
386<COMMAND_OUTPUT>
387Session pathWithSpaces created.
388Traces will be written in /home/user/hallo user/here/pathWithSpaces-20120209-095418
389</COMMAND_OUTPUT>
390</SCENARIO>
391
392####################################################################
393# Scenario: Test "lttng destroy <session>
394####################################################################
395
396<SCENARIO>
397DestroySession1
398<COMMAND_INPUT>
399lttng destroy mysession2
400</COMMAND_INPUT>
401<COMMAND_RESULT>
4020
403</COMMAND_RESULT>
404<COMMAND_OUTPUT>
405Session mysession2 destroyed.
406</COMMAND_OUTPUT>
407</SCENARIO>
408
409####################################################################
410# Scenario: Test "lttng enable-channel ..." with different inputs
411####################################################################
412
413<SCENARIO>
414ChannelHandling
415<COMMAND_INPUT>
416lttng enable-channel mychannel0,mychannel1 -k -s mysession2 --overwrite --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100
417</COMMAND_INPUT>
418<COMMAND_RESULT>
4190
420</COMMAND_RESULT>
421<COMMAND_OUTPUT>
422Kernel channel mychannel0 enabled for session mysession2
423Kernel channel mychannel1 enabled for session mysession2
424</COMMAND_OUTPUT>
425
426<COMMAND_INPUT>
427lttng enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200
428</COMMAND_INPUT>
429<COMMAND_RESULT>
4300
431</COMMAND_RESULT>
432<COMMAND_OUTPUT>
433UST channel channel0 enabled for session mysession2
434</COMMAND_OUTPUT>
435
436<COMMAND_INPUT>
437lttng enable-channel mychannel0,mychannel1 -k -s mysession2
438</COMMAND_INPUT>
439<COMMAND_RESULT>
4400
441</COMMAND_RESULT>
442<COMMAND_OUTPUT>
443Kernel channel mychannel0 enabled for session mysession2
444Kernel channel mychannel1 enabled for session mysession2
445</COMMAND_OUTPUT>
446
447<COMMAND_INPUT>
448lttng enable-channel ustChannel -u -s mysession2
449</COMMAND_INPUT>
450<COMMAND_RESULT>
4510
452</COMMAND_RESULT>
453<COMMAND_OUTPUT>
454UST channel mychannel0 enabled for session mysession2
455</COMMAND_OUTPUT>
456
457<COMMAND_INPUT>
458lttng disable-channel mychannel0,mychannel1 -k -s mysession2
459</COMMAND_INPUT>
460<COMMAND_RESULT>
4610
462</COMMAND_RESULT>
463<COMMAND_OUTPUT>
464Kernel channel mychannel0 disabled for session mysession2
465Kernel channel mychannel1 disabled for session mysession2
466</COMMAND_OUTPUT>
467
468<COMMAND_INPUT>
469lttng disable-channel ustChannel -u -s mysession2
470</COMMAND_INPUT>
471<COMMAND_RESULT>
4720
473</COMMAND_RESULT>
474<COMMAND_OUTPUT>
475UST channel mychannel0 enabled for session mysession2
476</COMMAND_OUTPUT>
477</SCENARIO>
478
479
480####################################################################
481# Scenario: Test "lttng enable-events ..." with different inputs
482####################################################################
483<SCENARIO>
484EventHandling
485
486# Tracepoint test cases
487
488<COMMAND_INPUT>
489lttng enable-event block_rq_remap,block_bio_remap,softirq_entry -k -s mysession2 --tracepoint
490</COMMAND_INPUT>
491<COMMAND_RESULT>
4920
493</COMMAND_RESULT>
494<COMMAND_OUTPUT>
495kernel event block_rq_remap created in channel channel0
496kernel event block_bio_remap created in channel channel0
497kernel event softirq_entry created in channel channel0
498</COMMAND_OUTPUT>
499
500<COMMAND_INPUT>
501lttng enable-event -a -k -s mysession2 -c mychannel --tracepoint
502</COMMAND_INPUT>
503<COMMAND_RESULT>
5040
505</COMMAND_RESULT>
506<COMMAND_OUTPUT>
507All kernel tracepoints are enabled in channel channel0
508</COMMAND_OUTPUT>
509
510<COMMAND_INPUT>
511lttng enable-event ust_tests_hello:tptest_sighandler -u -s mysession2 -c mychannel --tracepoint
512</COMMAND_INPUT>
513<COMMAND_RESULT>
5140
515</COMMAND_RESULT>
516<COMMAND_OUTPUT>
517UST event ust_tests_hello:tptest_sighandler created in channel mychannel
518</COMMAND_OUTPUT>
519
520<COMMAND_INPUT>
521lttng enable-event -a -u -s mysession2 -c mychannel --tracepoint
522</COMMAND_INPUT>
523<COMMAND_RESULT>
5240
525</COMMAND_RESULT>
526<COMMAND_OUTPUT>
527All UST tracepoints are enabled in channel mychannel
528</COMMAND_OUTPUT>
529
530# Syscall test cases
531
532<COMMAND_INPUT>
533lttng enable-event -a -k -s mysession2 --syscall
534</COMMAND_INPUT>
535<COMMAND_RESULT>
5360
537</COMMAND_RESULT>
538<COMMAND_OUTPUT>
539All kernel system calls are enabled in channel channel0
540</COMMAND_OUTPUT>
541
542<COMMAND_INPUT>
543lttng enable-event -a -k -s mysession2 -c mychannel --syscall
544</COMMAND_INPUT>
545<COMMAND_RESULT>
5460
547</COMMAND_RESULT>
548<COMMAND_OUTPUT>
549All kernel system calls are enabled in channel mychannel
550</COMMAND_OUTPUT>
551
552# dynamic probe/function probe test cases
553
554<COMMAND_INPUT>
555lttng enable-event myevent0 -k -s mysession2 --function 0xc0101340
556</COMMAND_INPUT>
557<COMMAND_RESULT>
5580
559</COMMAND_RESULT>
560<COMMAND_OUTPUT>
561kernel event myevent0 created in channel mychannel
562</COMMAND_OUTPUT>
563
564<COMMAND_INPUT>
565lttng enable-event myevent1 -k -s mysession2 -c mychannel --probe init_post
566</COMMAND_INPUT>
567<COMMAND_RESULT>
5680
569</COMMAND_RESULT>
570<COMMAND_OUTPUT>
571kernel event myevent1 created in channel mychannel
572</COMMAND_OUTPUT>
573
574# log level test cases
575
576<COMMAND_INPUT>
577lttng enable-event myevent4 -u -s mysession2 --loglevel-only TRACE_DEBUG
578</COMMAND_INPUT>
579<COMMAND_RESULT>
5800
581</COMMAND_RESULT>
582<COMMAND_OUTPUT>
583UST event myevent4 created in channel channel0
584</COMMAND_OUTPUT>
585
586<COMMAND_INPUT>
587lttng enable-event myevent5 -u -s mysession2 -c mychannel --loglevel TRACE_DEBUG_FUNCTION
588</COMMAND_INPUT>
589<COMMAND_RESULT>
5900
591</COMMAND_RESULT>
592<COMMAND_OUTPUT>
593UST event myevent5 created in channel mychannel
594</COMMAND_OUTPUT>
595
596</SCENARIO>
597
4ea599a5
BH
598####################################################################
599# Scenario: Test "lttng add-context -h" and lttng add-context ..." with different inputs
600####################################################################
601
602<SCENARIO>
603ContextHandling
604
605<COMMAND_INPUT>
606lttng add-context -h
607</COMMAND_INPUT>
608<COMMAND_RESULT>
6090
610</COMMAND_RESULT>
611<COMMAND_OUTPUT>
612usage: lttng add-context -t TYPE
613
614If no channel and no event is given (-c/-e), the context
615will be added to all events and all channels.
616Otherwise the context will be added only to the channel (-c)
617and/or event (-e) indicated.
618Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
619
620Options:
621 -h, --help Show this help
622 --list-options Simple listing of options
623 -s, --session NAME Apply to session name
624 -c, --channel NAME Apply to channel
625 -e, --event NAME Apply to event
626 -k, --kernel Apply to the kernel tracer
627 -u, --userspace Apply to the user-space tracer
628 -t, --type TYPE Context type. You can repeat that option on
629 the command line to specify multiple contexts at once.
630 (--kernel preempts --userspace)
631 TYPE can be one of the strings below:
632 pid, procname, prio, nice, vpid, tid, pthread_id,
633 vtid, ppid, vppid, perf:cpu-cycles, perf:cycles
634Example:
635This command will add the context information 'prio' and two perf
636counters (hardware branch misses and cache misses), to all events
637in the trace data output:
638# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
639
640</COMMAND_OUTPUT>
641
642<COMMAND_INPUT>
643lttng add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
644</COMMAND_INPUT>
645<COMMAND_RESULT>
6460
647</COMMAND_RESULT>
648<COMMAND_OUTPUT>
649UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
650UST context pid added to event sched_kthread_stop_ret channel mychannel
651</COMMAND_OUTPUT>
652</SCENARIO>
653
654<SCENARIO>
655ContextErrorHandling
656
657<COMMAND_INPUT>
658lttng add-context -h
659</COMMAND_INPUT>
660<COMMAND_RESULT>
6611
662</COMMAND_RESULT>
663<COMMAND_OUTPUT>
664usage: lttng add-context -t TYPE
d132bcc7 665
4ea599a5
BH
666If no channel and no event is given (-c/-e), the context
667will be added to all events and all channels.
668Otherwise the context will be added only to the channel (-c)
669and/or event (-e) indicated.
670Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
671
672Options:
673 -h, --help Show this help
674 --list-options Simple listing of options
675 -s, --session NAME Apply to session name
676 -c, --channel NAME Apply to channel
677 -e, --event NAME Apply to event
678 -k, --kernel Apply to the kernel tracer
679 -u, --userspace Apply to the user-space tracer
680 -t, --type TYPE Context type. You can repeat that option on
681 the command line to specify multiple contexts at once.
682 (--kernel preempts --userspace)
683 TYPE can be one of the strings below:
684 pid, procname, prio, nice, vpid, tid, pthread_id,
685 vtid, ppid, vppid, perf:cpu-cycles, perf:cycles
686Example:
687This command will add the context information 'prio' and two perf
688counters (hardware branch misses and cache misses), to all events
689in the trace data output:
690# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
691
692</COMMAND_OUTPUT>
693
694<COMMAND_INPUT>
695lttng add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
696</COMMAND_INPUT>
697<COMMAND_RESULT>
6981
699</COMMAND_RESULT>
700<COMMAND_OUTPUT>
701UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
702UST context pid added to event sched_kthread_stop_ret channel mychannel
703</COMMAND_OUTPUT>
704
705</SCENARIO>
706
707<SCENARIO>
708CalibrateHandling
709<COMMAND_INPUT>
710lttng calibrate -k --function
711</COMMAND_INPUT>
712<COMMAND_RESULT>
7130
714</COMMAND_RESULT>
715<COMMAND_OUTPUT>
716Kernel calibration done
717</COMMAND_OUTPUT>
718
719<COMMAND_INPUT>
720lttng calibrate -u --function
721</COMMAND_INPUT>
722<COMMAND_RESULT>
7231
724</COMMAND_RESULT>
725<COMMAND_OUTPUT>
726Kernel calibration done
727</COMMAND_OUTPUT>
728
729</SCENARIO>
This page took 0.052932 seconds and 5 git commands to generate.