3 * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
4 * PROPRIETARY/CONFIDENTIAL
6 * This software is the confidential and proprietary information of SAMSUNG
7 * ELECTRONICS ("Confidential Information"). You agree and acknowledge that
8 * this software is owned by Samsung and you shall not disclose such
9 * Confidential Information and shall use it only in accordance with the terms
10 * of the license agreement you entered into with SAMSUNG ELECTRONICS. SAMSUNG
11 * make no representations or warranties about the suitability of the software,
12 * either express or implied, including but not limited to the implied
13 * warranties of merchantability, fitness for a particular purpose, or
14 * non-infringement. SAMSUNG shall not be liable for any damages suffered by
15 * licensee arising out of or related to this software.
22 #define API_NAME_HAPTIC_GET_DEVICE_COUNT "haptic_get_count"
23 #define API_NAME_HAPTIC_INITALIZE "haptic_initialize"
24 #define API_NAME_HAPTIC_DEINITALIZE "haptic_deinitialize"
26 static void startup(void);
27 static void cleanup(void);
29 void (*tet_startup)(void) = startup;
30 void (*tet_cleanup)(void) = cleanup;
33 static void utc_haptic_get_count_p(void);
34 static void utc_haptic_initialize_p(void);
35 static void utc_haptic_deinitialize_p(void);
36 static void utc_haptic_deinitialize_n(void);
39 POSITIVE_TC_IDX = 0x01,
43 struct tet_testlist tet_testlist[] = {
44 { utc_haptic_get_count_p, POSITIVE_TC_IDX},
45 { utc_haptic_initialize_p, POSITIVE_TC_IDX},
46 { utc_haptic_deinitialize_p, POSITIVE_TC_IDX},
47 { utc_haptic_deinitialize_n, NEGATIVE_TC_IDX},
51 static void startup(void)
56 static void cleanup(void)
61 static void utc_haptic_get_count_p(void)
64 err = haptic_get_count(&cnt);
67 dts_fail(API_NAME_HAPTIC_GET_DEVICE_COUNT);
70 dts_pass(API_NAME_HAPTIC_GET_DEVICE_COUNT);
74 static void utc_haptic_initialize_p(void)
76 int err = haptic_initialize();
77 haptic_deinitialize();
80 dts_fail(API_NAME_HAPTIC_INITALIZE);
83 dts_pass(API_NAME_HAPTIC_INITALIZE);
87 static void utc_haptic_deinitialize_p(void)
92 err = haptic_deinitialize();
95 dts_fail(API_NAME_HAPTIC_DEINITALIZE);
98 dts_pass(API_NAME_HAPTIC_DEINITALIZE);
102 static void utc_haptic_deinitialize_n(void)
106 err = haptic_deinitialize();
109 dts_pass(API_NAME_HAPTIC_DEINITALIZE);
112 dts_fail(API_NAME_HAPTIC_DEINITALIZE);