Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC


Commits:
ff13274d by Alexandre Janniaux at 2024-03-10T11:45:10+00:00
test: meson.build: add clock test

The test exists since 08950258ef982204319ea48af93603ffef19bd5c.

- - - - -
dd92a11c by Alexandre Janniaux at 2024-03-10T11:45:10+00:00
test: meson.build: add player monotonic test

The test exists since 5e9747b6db6973ed8af0e20512f547b6ec1900a8.

- - - - -
3ba89ea8 by Alexandre Janniaux at 2024-03-10T11:45:10+00:00
test/libvlc: meta: skip test if taglib is absent

The test depends on the Taglib module currently, in particular to supply
the artist name to the input item.

- - - - -


2 changed files:

- test/libvlc/meta.c
- test/src/meson.build


Changes:

=====================================
test/libvlc/meta.c
=====================================
@@ -26,7 +26,9 @@
 #include "test.h"
 #include "media_utils.h"
 
-static void test_meta (const char ** argv, int argc)
+#include <vlc_modules.h>
+
+static int test_meta (const char ** argv, int argc)
 {
     libvlc_instance_t *vlc;
     libvlc_media_t *media;
@@ -37,6 +39,9 @@ static void test_meta (const char ** argv, int argc)
     vlc = libvlc_new (argc, argv);
     assert (vlc != NULL);
 
+    if (!module_exists("taglib"))
+        return 77;
+
     media = libvlc_media_new_path(SRCDIR "/samples/meta.mp3");
     assert( media );
 
@@ -55,6 +60,8 @@ static void test_meta (const char ** argv, int argc)
     free (artist);
     libvlc_media_release (media);
     libvlc_release (vlc);
+
+    return 0;
 }
 
 
@@ -62,7 +69,5 @@ int main (void)
 {
     test_init();
 
-    test_meta (test_defaults_args, test_defaults_nargs);
-
-    return 0;
+    return test_meta (test_defaults_args, test_defaults_nargs);
 }


=====================================
test/src/meson.build
=====================================
@@ -18,6 +18,16 @@ vlc_tests += {
     'suite' : ['src', 'test_src'],
 }
 
+vlc_tests += {
+    'name' : 'test_src_clock_clock',
+    'sources' : files(
+        'clock/clock.c',
+        '../../src/clock/clock.c',
+        '../../src/clock/clock_internal.c'),
+    'suite' : ['src', 'test_src'],
+    'link_with' : [libvlc, libvlccore],
+}
+
 vlc_tests += {
     'name' : 'test_src_misc_variables',
     'sources' : files('misc/variables.c'),
@@ -79,6 +89,15 @@ vlc_tests += {
     # 'zvbi', ...],
 }
 
+vlc_tests += {
+    'name' : 'test_src_player_monotonic_clock',
+    'sources' : files('player/player.c'),
+    'suite' : ['src', 'test_src'],
+    'c_args' : ['-DTEST_CLOCK_MONOTONIC'],
+    'link_with' : [libvlc, libvlccore],
+    'module_depends' : vlc_plugins_targets.keys()
+}
+
 vlc_tests += {
     'name' : 'test_src_video_output',
     'sources' : files(



View it on GitLab: 
https://code.videolan.org/videolan/vlc/-/compare/a4b5c96472b5650134e4b844898a51f1b3fc0fbe...3ba89ea810a56279d0740df470f612a81fc5abc5

-- 
View it on GitLab: 
https://code.videolan.org/videolan/vlc/-/compare/a4b5c96472b5650134e4b844898a51f1b3fc0fbe...3ba89ea810a56279d0740df470f612a81fc5abc5
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance
_______________________________________________
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to