/* * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #include #include #include static void startup(void); static void cleanup(void); void (*tet_startup)(void) = startup; void (*tet_cleanup)(void) = cleanup; static void startup(void) { // TODO : How to copy sample image???? } static void cleanup(void) { /* end of TC */ } static void utc_uix_face_component_create_negative(void) { static const char szFunc[] = "face_component_create"; int err = face_component_create(NULL); dts_check_lt(szFunc, err, FACE_ERROR_NONE); } static void utc_uix_face_component_destroy_negative(void) { static const char szFunc[] = "face_component_destroy"; int err; err = face_component_destroy(NULL); dts_check_lt(szFunc, err, FACE_ERROR_NONE); } static void utc_uix_face_component_get_face_rect_negative(void) { static const char szFunc[] = "face_component_get_face_rect"; int err; face_component_h face_component; err = face_component_create(&face_component); face_rect_s face; err = face_component_get_face_rect(NULL, &face); dts_check_lt(szFunc, err, FACE_ERROR_NONE); err = face_component_destroy(face_component); } static void utc_uix_face_component_get_left_eye_point_negative(void) { static const char szFunc[] = "face_component_get_left_eye_point"; int err; face_component_h face_component; err = face_component_create(&face_component); face_point_s point; err = face_component_get_left_eye_point(NULL, &point); dts_check_lt(szFunc, err, FACE_ERROR_NONE); err = face_component_get_left_eye_point(face_component, NULL); dts_check_lt(szFunc, err, FACE_ERROR_NONE); err = face_component_destroy(face_component); } static void utc_uix_face_component_get_right_eye_point_negative(void) { static const char szFunc[] = "face_component_get_right_eye_point"; int err; face_component_h face_component; err = face_component_create(&face_component); face_point_s point; err = face_component_get_right_eye_point(NULL, &point); dts_check_lt(szFunc, err, FACE_ERROR_NONE); err = face_component_get_right_eye_point(face_component, NULL); dts_check_lt(szFunc, err, FACE_ERROR_NONE); err = face_component_destroy(face_component); } static void utc_uix_face_component_get_mouse_rect_negative(void) { static const char szFunc[] = "face_component_get_mouse_rect"; int err; face_component_h face_component; err = face_component_create(&face_component); face_rect_s mouse; err = face_component_get_mouse_rect(face_component, NULL); dts_check_lt(szFunc, err, FACE_ERROR_NONE); err = face_component_get_mouse_rect(NULL, &mouse); dts_check_lt(szFunc, err, FACE_ERROR_NONE); err = face_component_destroy(face_component); } struct tet_testlist tet_testlist[] = { { utc_uix_face_component_create_negative, 1}, { utc_uix_face_component_destroy_negative, 2}, { utc_uix_face_component_get_face_rect_negative, 3}, { utc_uix_face_component_get_left_eye_point_negative, 4}, { utc_uix_face_component_get_right_eye_point_negative, 5}, { utc_uix_face_component_get_mouse_rect_negative, 6}, { NULL, 0}, };