[rygel] tests: Update ByteSeek unit test for commit b92b7a8



commit 684a60153d473fc2417c67c6b0aa2a502dbb7f1d
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date:   Tue Sep 14 00:19:55 2010 +0300

    tests: Update ByteSeek unit test for commit b92b7a8

 tests/rygel-http-byte-seek-test.vala |   12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)
---
diff --git a/tests/rygel-http-byte-seek-test.vala b/tests/rygel-http-byte-seek-test.vala
index d6b2080..d0a82cc 100644
--- a/tests/rygel-http-byte-seek-test.vala
+++ b/tests/rygel-http-byte-seek-test.vala
@@ -197,11 +197,13 @@ private class Rygel.HTTPByteSeekTest : GLib.Object {
             assert (seek.total_length == request.item.size);
         }
 
-        var header = request.msg.response_headers.get_one ("Accept-Ranges");
-        assert (header == "bytes");
-        header = request.msg.response_headers.get_one ("Content-Range");
-        assert (header != null);
-        assert (this.range_regex.match (header));
+        if (request.msg.request_headers.get_one ("Range") != null) {
+            var header = request.msg.response_headers.get_one ("Accept-Ranges");
+            assert (header == "bytes");
+            header = request.msg.response_headers.get_one ("Content-Range");
+            assert (header != null);
+            assert (this.range_regex.match (header));
+        }
 
         assert (request.msg.response_headers.get_content_length () ==
                 seek.length);



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