extern int utc_media_player_set_sound_type_p(void);
extern int utc_media_player_set_sound_type_n(void);
extern int utc_media_player_set_sound_type_n2(void);
+extern int utc_media_player_set_audio_policy_info_p(void);
+extern int utc_media_player_set_audio_policy_info_n(void);
extern int utc_media_player_set_subtitle_path_p(void);
extern int utc_media_player_set_subtitle_path_n(void);
extern int utc_media_player_set_display_visible_p(void);
{"utc_media_player_get_volume_n", utc_media_player_get_volume_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_sound_type_p", utc_media_player_set_sound_type_p, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_sound_type_n", utc_media_player_set_sound_type_n, utc_media_player_startup, utc_media_player_cleanup},
- {"utc_media_player_set_sound_type_n2", utc_media_player_set_sound_type_n2, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_sound_type_n2", utc_media_player_set_sound_type_n2, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_audio_policy_info_p", utc_media_player_set_audio_policy_info_p, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_audio_policy_info_n", utc_media_player_set_audio_policy_info_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_subtitle_path_p", utc_media_player_set_subtitle_path_p, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_subtitle_path_n", utc_media_player_set_subtitle_path_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_display_visible_p", utc_media_player_set_display_visible_p, utc_media_player_startup, utc_media_player_cleanup},
extern int utc_media_player_set_sound_type_p(void);
extern int utc_media_player_set_sound_type_n(void);
extern int utc_media_player_set_sound_type_n2(void);
+extern int utc_media_player_set_audio_policy_info_p(void);
+extern int utc_media_player_set_audio_policy_info_n(void);
extern int utc_media_player_set_subtitle_path_p(void);
extern int utc_media_player_set_subtitle_path_n(void);
extern int utc_media_player_set_display_visible_p(void);
{"utc_media_player_set_sound_type_p", utc_media_player_set_sound_type_p, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_sound_type_n", utc_media_player_set_sound_type_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_sound_type_n2", utc_media_player_set_sound_type_n2, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_audio_policy_info_p", utc_media_player_set_audio_policy_info_p, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_audio_policy_info_n", utc_media_player_set_audio_policy_info_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_subtitle_path_p", utc_media_player_set_subtitle_path_p, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_subtitle_path_n", utc_media_player_set_subtitle_path_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_display_visible_p", utc_media_player_set_display_visible_p, utc_media_player_startup, utc_media_player_cleanup},
extern int utc_media_player_set_sound_type_p(void);
extern int utc_media_player_set_sound_type_n(void);
extern int utc_media_player_set_sound_type_n2(void);
+extern int utc_media_player_set_audio_policy_info_p(void);
+extern int utc_media_player_set_audio_policy_info_n(void);
extern int utc_media_player_set_subtitle_path_p(void);
extern int utc_media_player_set_subtitle_path_n(void);
extern int utc_media_player_set_display_visible_p(void);
{"utc_media_player_get_volume_n", utc_media_player_get_volume_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_sound_type_p", utc_media_player_set_sound_type_p, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_sound_type_n", utc_media_player_set_sound_type_n, utc_media_player_startup, utc_media_player_cleanup},
- {"utc_media_player_set_sound_type_n2", utc_media_player_set_sound_type_n2, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_sound_type_n2", utc_media_player_set_sound_type_n2, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_audio_policy_info_p", utc_media_player_set_audio_policy_info_p, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_audio_policy_info_n", utc_media_player_set_audio_policy_info_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_subtitle_path_p", utc_media_player_set_subtitle_path_p, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_subtitle_path_n", utc_media_player_set_subtitle_path_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_display_visible_p", utc_media_player_set_display_visible_p, utc_media_player_startup, utc_media_player_cleanup},
extern int utc_media_player_set_sound_type_p(void);
extern int utc_media_player_set_sound_type_n(void);
extern int utc_media_player_set_sound_type_n2(void);
+extern int utc_media_player_set_audio_policy_info_p(void);
+extern int utc_media_player_set_audio_policy_info_n(void);
extern int utc_media_player_set_subtitle_path_p(void);
extern int utc_media_player_set_subtitle_path_n(void);
extern int utc_media_player_set_display_visible_p(void);
{"utc_media_player_get_volume_n", utc_media_player_get_volume_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_sound_type_p", utc_media_player_set_sound_type_p, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_sound_type_n", utc_media_player_set_sound_type_n, utc_media_player_startup, utc_media_player_cleanup},
- {"utc_media_player_set_sound_type_n2", utc_media_player_set_sound_type_n2, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_sound_type_n2", utc_media_player_set_sound_type_n2, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_audio_policy_info_p", utc_media_player_set_audio_policy_info_p, utc_media_player_startup, utc_media_player_cleanup},
+ {"utc_media_player_set_audio_policy_info_n", utc_media_player_set_audio_policy_info_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_subtitle_path_p", utc_media_player_set_subtitle_path_p, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_subtitle_path_n", utc_media_player_set_subtitle_path_n, utc_media_player_startup, utc_media_player_cleanup},
{"utc_media_player_set_display_visible_p", utc_media_player_set_display_visible_p, utc_media_player_startup, utc_media_player_cleanup},
return 0;
}
+/**
+ * @testcase utc_media_player_set_sound_type_n2
+ * @since_tizen 2.3.1
+ * @description Negative test case to set sound type
+ */
int utc_media_player_set_sound_type_n2(void)
{
sound_type_e type;
}
/**
+ * @testcase utc_media_player_set_audio_policy_info_p
+ * @since_tizen 3.0
+ * @description Positive test case to set audio policy info
+ */
+int utc_media_player_set_audio_policy_info_p(void)
+{
+ sound_type_e type;
+ player_state_e state;
+
+ int ret = player_get_state (player, &state);
+ assert_eq(ret, PLAYER_ERROR_NONE);
+ if (state != PLAYER_STATE_IDLE){
+ player_unprepare(player);
+ }
+
+ ret = player_get_state (player, &state);
+ assert_eq(ret, PLAYER_ERROR_NONE);
+
+ if (state == PLAYER_STATE_IDLE){
+ set_sound_stream_info();
+ ret = player_set_audio_policy_info(player, g_stream_info_h);
+ assert_eq(ret, PLAYER_ERROR_NONE);
+ }
+ return 0;
+}
+
+/**
+ * @testcase utc_media_player_set_audio_policy_info_n
+ * @since_tizen 3.0
+ * @description Negative test case to set audio policy info
+ */
+int utc_media_player_set_audio_policy_info_n(void)
+{
+ sound_type_e type;
+ player_state_e state;
+
+ int ret = player_get_state (player, &state);
+ assert_eq(ret, PLAYER_ERROR_NONE);
+ if (state != PLAYER_STATE_IDLE){
+ player_unprepare(player);
+ }
+
+ ret = player_get_state (player, &state);
+ assert_eq(ret, PLAYER_ERROR_NONE);
+
+ if (state == PLAYER_STATE_IDLE){
+ ret = player_set_audio_policy_info(NULL, NULL);
+ assert_eq(ret, PLAYER_ERROR_INVALID_PARAMETER);
+ }
+ return 0;
+}
+
+/**
* @testcase utc_media_player_set_subtitle_path_p
* @since_tizen 2.3.1
* @description Positive test case to set subtitle path