guix-commits
[Top][All Lists]
Advanced

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

05/06: publish: Add test for non-GET queries.


From: Ludovic Courtès
Subject: 05/06: publish: Add test for non-GET queries.
Date: Thu, 22 Mar 2018 07:55:54 -0400 (EDT)

civodul pushed a commit to branch master
in repository guix.

commit c1cd155aa8afa17e60491c85e8f226f99257d395
Author: Ludovic Courtès <address@hidden>
Date:   Thu Mar 22 12:51:23 2018 +0100

    publish: Add test for non-GET queries.
    
    * tests/publish.scm ("non-GET query"): New test.
---
 tests/publish.scm | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/tests/publish.scm b/tests/publish.scm
index 8c88a8c..a4a52a4 100644
--- a/tests/publish.scm
+++ b/tests/publish.scm
@@ -483,4 +483,12 @@ FileSize: ~a~%"
   (let ((uri (publish-uri "/log/does-not-exist")))
     (response-code (http-get uri))))
 
+(test-equal "non-GET query"
+  '(200 404)
+  (let ((path (string-append "/" (store-path-hash-part %item)
+                             ".narinfo")))
+    (map response-code
+         (list (http-get (publish-uri path))
+               (http-post (publish-uri path))))))
+
 (test-end "publish")



reply via email to

[Prev in Thread] Current Thread [Next in Thread]