]> granicus.if.org Git - taglib/commitdiff
Missing file
authorLukáš Lalinský <lalinsky@gmail.com>
Sun, 11 Jul 2010 17:45:47 +0000 (17:45 +0000)
committerLukáš Lalinský <lalinsky@gmail.com>
Sun, 11 Jul 2010 17:45:47 +0000 (17:45 +0000)
git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/kdesupport/taglib@1148734 283d02a7-25f6-0310-bc7c-ecb5cbfe19da

tests/CMakeLists.txt
tests/test_wav.cpp [new file with mode: 0644]

index 62898a589fb28e607c0ac40bb6b99ee59c59207b..f5b80c6912a93e08d846751ec1db0ee638f5e276 100644 (file)
@@ -41,7 +41,7 @@ SET(test_runner_SRCS
   test_flac.cpp
   test_ape.cpp
   test_apetag.cpp
-  #test_wav.cpp
+  test_wav.cpp
 )
 IF(WITH_MP4)
    SET(test_runner_SRCS ${test_runner_SRCS}
diff --git a/tests/test_wav.cpp b/tests/test_wav.cpp
new file mode 100644 (file)
index 0000000..38a9a0f
--- /dev/null
@@ -0,0 +1,28 @@
+#include <cppunit/extensions/HelperMacros.h>
+#include <string>
+#include <stdio.h>
+#include <tag.h>
+#include <tbytevectorlist.h>
+#include <wavfile.h>
+#include "utils.h"
+
+using namespace std;
+using namespace TagLib;
+
+class TestWAV : public CppUnit::TestFixture
+{
+  CPPUNIT_TEST_SUITE(TestWAV);
+  CPPUNIT_TEST(testLength);
+  CPPUNIT_TEST_SUITE_END();
+
+public:
+
+  void testLength()
+  {
+    RIFF::WAV::File f("data/empty.wav");
+    CPPUNIT_ASSERT_EQUAL(3, f.audioProperties()->length());
+  }
+
+};
+
+CPPUNIT_TEST_SUITE_REGISTRATION(TestWAV);