<commit_before>
project(fluidsynth-test)

ENABLE_TESTING()
include ( FluidUnitTest )

## add unit tests here ##
ADD_FLUID_TEST(test_sample_cache)
ADD_FLUID_TEST(test_sfont_loading)
ADD_FLUID_TEST(test_defsfont_preset_iteration)
ADD_FLUID_TEST(test_sample_rate_change)

if ( LIBSNDFILE_HASVORBIS )
    ADD_FLUID_TEST(test_sf3_sfont_loading)
    ADD_FLUID_TEST(test_sf3_defsfont_preset_iteration)
endif ( LIBSNDFILE_HASVORBIS )


add_custom_target(check
COMMAND ${CMAKE_CTEST_COMMAND} -C $<CONFIG>  --output-on-failure
DEPENDS
test_sample_cache
test_sfont_loading
test_defsfont_preset_iteration
test_sample_rate_change

test_sf3_sfont_loading
test_sf3_defsfont_preset_iteration
)<commit_msg>Fix tests without libsndfile. Not pretty, welcome a better solution!<commit_after>
project(fluidsynth-test)

ENABLE_TESTING()
include ( FluidUnitTest )

## add unit tests here ##
ADD_FLUID_TEST(test_sample_cache)
ADD_FLUID_TEST(test_sfont_loading)
ADD_FLUID_TEST(test_defsfont_preset_iteration)
ADD_FLUID_TEST(test_sample_rate_change)

if ( LIBSNDFILE_HASVORBIS )
    ADD_FLUID_TEST(test_sf3_sfont_loading)
    ADD_FLUID_TEST(test_sf3_defsfont_preset_iteration)
endif ( LIBSNDFILE_HASVORBIS )


if ( LIBSNDFILE_HASVORBIS )
    add_custom_target(check
    COMMAND ${CMAKE_CTEST_COMMAND} -C $<CONFIG>  --output-on-failure
    DEPENDS
    test_sample_cache
    test_sfont_loading
    test_defsfont_preset_iteration
    test_sample_rate_change
    test_sf3_sfont_loading
    test_sf3_defsfont_preset_iteration
    )
else ( LIBSNDFILE_HASVORBIS )
    add_custom_target(check
    COMMAND ${CMAKE_CTEST_COMMAND} -C $<CONFIG>  --output-on-failure
    DEPENDS
    test_sample_cache
    test_sfont_loading
    test_defsfont_preset_iteration
    test_sample_rate_change
    )
endif ( LIBSNDFILE_HASVORBIS )
{'fraction_non_alphanumeric': 0.06053811659192825, 'fraction_numerical': 0.004484304932735426, 'mean_word_length': 6.628205128205129, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2182769', 'n_tokens_mistral': 713, 'n_tokens_neox': 698, 'n_words': 90}