mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-18 14:26:43 +00:00
tests: videotimecode: fix floating point comparisons
Comparing floats for equality is not necessarily going to work reliably, so use fail_unless_equals_float() for this. Test would fail on x86 (Intel Atom x5-Z8300).
This commit is contained in:
parent
7c0ec13942
commit
d9da603db6
1 changed files with 1 additions and 1 deletions
|
@ -332,7 +332,7 @@ GST_START_TEST (videotimecode_dailyjam_todatetime)
|
||||||
fail_unless (g_date_time_get_day_of_month (dt2) == 29);
|
fail_unless (g_date_time_get_day_of_month (dt2) == 29);
|
||||||
fail_unless (g_date_time_get_hour (dt2) == 11);
|
fail_unless (g_date_time_get_hour (dt2) == 11);
|
||||||
fail_unless (g_date_time_get_minute (dt2) == 36);
|
fail_unless (g_date_time_get_minute (dt2) == 36);
|
||||||
fail_unless (g_date_time_get_seconds (dt2) == 53.04);
|
fail_unless_equals_float (g_date_time_get_seconds (dt2), 53.04);
|
||||||
|
|
||||||
gst_video_time_code_free (tc1);
|
gst_video_time_code_free (tc1);
|
||||||
g_date_time_unref (dt2);
|
g_date_time_unref (dt2);
|
||||||
|
|
Loading…
Reference in a new issue