aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2014-02-07 23:41:06 +0100
committerMax Kellermann <max@duempel.org>2014-02-07 23:41:06 +0100
commitbe081929f4523376db2df52903230d3b20dc54e9 (patch)
treee48e32ba99511d8d326ff3e7195d1c0e35b661fc /test
parentb0b086d47302867291f2241880b54429f0347691 (diff)
downloadmpd-be081929f4523376db2df52903230d3b20dc54e9.tar.gz
mpd-be081929f4523376db2df52903230d3b20dc54e9.tar.xz
mpd-be081929f4523376db2df52903230d3b20dc54e9.zip
storage/local: remove utf8 path from constructor
Build the UTF-8 version of the path automatically in the constructor.
Diffstat (limited to 'test')
-rw-r--r--test/test_translate_song.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/test_translate_song.cxx b/test/test_translate_song.cxx
index 6ef3a13f5..bcd3e8646 100644
--- a/test/test_translate_song.cxx
+++ b/test/test_translate_song.cxx
@@ -38,9 +38,8 @@ uri_supported_scheme(const char *uri)
return memcmp(uri, "http://", 7) == 0;
}
-const char *const music_directory = "/music";
-static Storage *const storage = CreateLocalStorage(music_directory,
- Path::FromFS(music_directory));
+static const char *const music_directory = "/music";
+static Storage *storage;
static void
BuildTag(gcc_unused TagBuilder &tag)
@@ -308,6 +307,8 @@ CPPUNIT_TEST_SUITE_REGISTRATION(TranslateSongTest);
int
main(gcc_unused int argc, gcc_unused char **argv)
{
+ storage = CreateLocalStorage(Path::FromFS(music_directory));
+
CppUnit::TextUi::TestRunner runner;
auto &registry = CppUnit::TestFactoryRegistry::getRegistry();
runner.addTest(registry.makeTest());