[rygel] tests: Mock XBoxHacks for unit-tests



commit f70e64d265f69d40ed729c0659e133b62f857086
Author: Jens Georg <mail jensge org>
Date:   Sat May 7 21:26:11 2011 +0200

    tests: Mock XBoxHacks for unit-tests

 tests/rygel-http-get-test.vala |   14 ++++++++++++++
 1 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/tests/rygel-http-get-test.vala b/tests/rygel-http-get-test.vala
index 7f3acde..f40ba65 100644
--- a/tests/rygel-http-get-test.vala
+++ b/tests/rygel-http-get-test.vala
@@ -29,6 +29,20 @@ public errordomain Rygel.TestError {
     TIMEOUT
 }
 
+public errordomain Rygel.XBoxHacksError {
+    NA
+}
+
+public class Rygel.XBoxHacks {
+    public XBoxHacks.for_headers (MessageHeaders headers) throws Error {
+        throw new XBoxHacksError.NA ("");
+    }
+
+    public bool is_album_art_request (Message message) {
+        return false;
+    }
+}
+
 public class Rygel.HTTPGetTest : GLib.Object {
     protected HTTPServer server;
     protected HTTPClient client;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]