diff mbox series

[bug#62473,v3,1/4] gnu: Add ftest.

Message ID 01020187e5cad893-4db14f86-be13-4495-9fcf-7ae50d920f45-000000@eu-west-1.amazonses.com
State New
Headers show
Series OpenFoam update to version 10 | expand

Commit Message

reza May 4, 2023, 8:04 a.m. UTC
* gnu/packages/check.scm (ftest): New variable.
---
 gnu/packages/check.scm | 36 ++++++++++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)


base-commit: 7a0a186a32524d4156bf96786d708fab323cebff
-- 
2.39.2

Comments

Ludovic Courtès June 15, 2023, 9:56 p.m. UTC | #1
Hi reza,

Sorry for taking so long to get back to you.

As I wrote in April, could you please resend with ‘git send-email’ or
somehow ensure your mail user agent doesn’t use DOS-style line endings?

  https://issues.guix.gnu.org/62473#11

Thanks in advance!

Ludo’.
diff mbox series

Patch

diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm
index 17c2b7284e..8772095944 100644
--- a/gnu/packages/check.scm
+++ b/gnu/packages/check.scm
@@ -43,6 +43,7 @@ 
 ;;; Copyright © 2022 jgart <jgart@dismail.de>
 ;;; Copyright © 2023 Luis Felipe López Acevedo <luis.felipe.la@protonmail.com>
 ;;; Copyright © 2023 Timo Wilken <guix@twilken.net>
+;;; Copyright © 2023 Reza Housseini <reza@housseini.me>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -65,6 +66,7 @@  (define-module (gnu packages check)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages base)
   #:use-module (gnu packages bash)
+  #:use-module (gnu packages cmake)
   #:use-module (gnu packages compression)
   #:use-module (gnu packages linux)
   #:use-module (gnu packages llvm)
@@ -92,6 +94,7 @@  (define-module (gnu packages check)
   #:use-module (guix gexp)
   #:use-module (guix git-download)
   #:use-module (guix build-system cmake)
+  #:use-module (guix build-system copy)
   #:use-module (guix build-system glib-or-gtk)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
@@ -3530,3 +3533,36 @@  (define-public guile-proba
 to run test collections, and a library that includes a test runner and
 helpers for writing tests.")
     (license license:public-domain)))
+
+(define-public ftest
+  (package
+    (name "ftest")
+    ;; There aren't any releases and it looks
+    ;; more like a small side project. It is included for
+    ;; completness to run tests for package utfcpp
+    (version "bf75576064fce2e07f52cd63a3e410f12358728b")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/nemtrif/ftest")
+                    (commit version)))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "01yjhjnlq2gci8hkc6favwj0axq7y1vvnradsgcffby6h09x00b4"))))
+    ;; No CMakeLists.txt file provided, only one to run tests
+    (build-system copy-build-system)
+    (native-inputs (list cmake-minimal))
+    (arguments
+     `(#:install-plan '(("ftest.h" "include/ftest/"))
+       #:phases (modify-phases %standard-phases
+                  (add-before 'install 'check
+                    (lambda _
+                      (with-directory-excursion "tests"
+                        (invoke "cmake" ".")
+                        (invoke "make")
+                        (invoke "ctest")))))))
+    (home-page "https://github.com/nemtrif/ftest")
+    (synopsis "Simple and limited unit-test framework for C++")
+    (description "A simple and limited unit-test framework for C++")
+    (license license:asl2.0)))