Commit Graph

10 Commits

Author SHA1 Message Date
Jakub Tyszkowski
bdceceb9d4 android/unit: Add support for variable length data
This patch adds sending messages larger than just hal_hdr, and fixes
response verification which worked only for empty messages but was
failing when sending something more than just header.
2014-02-04 21:35:10 +01:00
Jakub Tyszkowski
639abb4ba9 android/unit: Add case for opcode without handler
This test case checks if IPC shuts down on unhandled opcode.
2014-02-04 21:35:10 +01:00
Jakub Tyszkowski
e7a054a8b2 android/unit: Add test cases for proper handler calls
This patch adds tests for calling proper opcode handler. Two handlers
are registered, but one always results in failure. No failure means that
proper opcode <-> handler maching is done by the ipc mechanism.
2014-02-04 21:35:10 +01:00
Jakub Tyszkowski
cca001f942 android/unit: Rename cmd handler
This handler responses for opcode == 1, thus should use proper naming to
avoid confision when more functions sending different responses will be
added.
2014-02-04 21:35:10 +01:00
Jakub Tyszkowski
aeed33339c android/unit: Fix checking for expected termination
This fix makes sure that when signalled termination is expected,
it actually happens. If IPC termination is expected no response will be
sent, so cmd_watch will never be executed. But if it is executed when
expecting termination, its a failure.
2014-02-04 21:35:10 +01:00
Szymon Janc
99052be6c2 android/unit: Rename tests names to be more descriptive 2014-02-03 14:15:00 +01:00
Marcin Kraglak
eeae8babb5 android/unit: Add /android_ipc/send_cmd_3 test case
This case will register service, next unregister it and send
command. Expected status is raise SIGTERM.
2014-02-03 14:15:00 +01:00
Marcin Kraglak
3ac803d029 android/unit: Add /android_ipc/send_cmd_2 test case
This will test sending command to previously registered service.
2014-02-03 14:15:00 +01:00
Marcin Kraglak
898ad7e90a android/unit: Add /android_ipc/send_cmd_1 test case
This test case will check if ipc lib will raise SIGTERM
after sending command to not registered service.
2014-02-03 14:15:00 +01:00
Marcin Kraglak
981459271d android/unit: Add android IPC unit tests
It will test ipc library. First test case will check
ipc_init() call.
2014-02-03 14:15:00 +01:00