mirror of
https://github.com/SFML/SFML.git
synced 2025-02-13 03:48:02 +08:00
Test loading sf::SoundBuffer
with non-ASCII filenames
This commit is contained in:
parent
594eb408cb
commit
52ef7c9955
@ -122,7 +122,21 @@ TEST_CASE("[Audio] sf::SoundBuffer", runAudioDeviceTests())
|
||||
|
||||
SECTION("Valid file")
|
||||
{
|
||||
REQUIRE(soundBuffer.loadFromFile("Audio/ding.flac"));
|
||||
SECTION("ASCII filename")
|
||||
{
|
||||
REQUIRE(soundBuffer.loadFromFile("Audio/ding.flac"));
|
||||
}
|
||||
|
||||
SECTION("Polish filename")
|
||||
{
|
||||
REQUIRE(soundBuffer.loadFromFile(U"Audio/ding-\u0144.flac"));
|
||||
}
|
||||
|
||||
SECTION("Emoji filename")
|
||||
{
|
||||
REQUIRE(soundBuffer.loadFromFile(U"Audio/ding-\U0001F40C.flac"));
|
||||
}
|
||||
|
||||
CHECK(soundBuffer.getSamples() != nullptr);
|
||||
CHECK(soundBuffer.getSampleCount() == 87798);
|
||||
CHECK(soundBuffer.getSampleRate() == 44100);
|
||||
|
Loading…
x
Reference in New Issue
Block a user