commit 1b3483eceb0dedb42f5b58a9d6b4e203cafd4d43
parent 43bc87da6cb3eaa8ae0aa0ef50bc7bc846f6c31d
Author: Alexander Kojevnikov <alexander@kojevnikov.com>
Date: Tue, 5 Mar 2013 09:42:45 -0800
Tidy
Diffstat:
4 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/tests/test-audio-info.cc b/tests/test-audio-info.cc
@@ -59,6 +59,9 @@ void test_audio_info()
{"2ch-44100Hz-V2.mp3", {"MP3 (MPEG audio layer 3)", 64000, 44100, 0, 2, MP3_T}},
};
for (const auto& item : files) {
- run([&] () { test_file(item.first, item.second); }, "audio info: " + item.first);
+ run(
+ "audio info: " + item.first,
+ [&] () { test_file(item.first, item.second); }
+ );
}
}
diff --git a/tests/test-utils.cc b/tests/test-utils.cc
@@ -43,5 +43,5 @@ static void test_vercmp()
void test_utils()
{
- run(test_vercmp, "vercmp");
+ run("vercmp", test_vercmp);
}
diff --git a/tests/test.cc b/tests/test.cc
@@ -37,7 +37,7 @@ int main()
}
}
-void run(std::function<void ()> func, const std::string& message)
+void run(const std::string& message, std::function<void ()> func)
{
std::cerr << message << std::endl;
func();
diff --git a/tests/test.h b/tests/test.h
@@ -24,7 +24,7 @@
#include <iostream>
#include <string>
-void run(std::function<void ()> func, const std::string& message);
+void run(const std::string& message, std::function<void ()> func);
extern int g_total;
extern int g_passes;