Subject: [bug#64249] [PATCH 3/9] gnu: Add ocaml-junit

From: [email-masked]
Date: Sun, 24 Dec 2023 17:43:38 +0100

From: Arnaud DABY-SEESARAM <[email-masked]>

* gnu/packages/ocaml.scm (ocaml-junit): New variable.

Change-Id: I69fd4302b0a178765a79a72801eed694b3bd3ebd
---
 gnu/packages/ocaml.scm | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 38bf7b2a7d4..f664f6db81b 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -1642,6 +1642,30 @@ (define-public ocaml-ounit
 other XUnit testing frameworks.")
     (license license:expat)))
 
+(define-public ocaml-junit
+  (package
+    (name "ocaml-junit")
+    (version "2.0.2")
+    (home-page "https://github.com/Khady/ocaml-junit")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append home-page "/archive/refs/tags/v" version ".tar.gz"))
+       (sha256
+        (base32 "00bbx5j8vsy9fqbc04xa3lsalaxicirmbczr65bllfk1afv43agx"))))
+    (build-system dune-build-system)
+    (arguments
+     `(#:package "junit"
+       #:phases (modify-phases %standard-phases
+                  (add-before 'build 'dune-subst
+                    (lambda _
+                      (invoke "dune" "subst") #t)))))
+    (properties `((upstream-name . "junit")))
+    (propagated-inputs (list ocaml-ounit ocaml-ptime ocaml-tyxml ocaml-odoc))
+    (synopsis "JUnit XML reports generation library")
+    (description "JUnit XML reports generation library")
+    (license #f)))
+
 (define-public camlzip
   (package
     (name "camlzip")
-- 
2.41.0