diff mbox series

[bug#65131,19/32] gnu: Add ruby-vagrant-spec.

Message ID 7355546d611ac4e12e0c8c32d670487f4baf9235.1691432343.git.h.goebel@crazy-compilers.com
State New
Headers show
Series Add vagrant, some vagrant plugins and required ruby modules | expand

Commit Message

Hartmut Goebel Aug. 7, 2023, 6:26 p.m. UTC
* gnu/packages/virtualization.scm (ruby-vagrant-spec): New variable.
---
 gnu/packages/virtualization.scm | 37 +++++++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)
diff mbox series

Patch

diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
index 9556fbc61e..cfba1f0898 100644
--- a/gnu/packages/virtualization.scm
+++ b/gnu/packages/virtualization.scm
@@ -29,6 +29,7 @@ 
 ;;; Copyright © 2022 Arun Isaac <arunisaac@systemreboot.net>
 ;;; Copyright © 2022 Zhu Zihao <all_but_last@163.com>
 ;;; Copyright © 2023 Juliana Sims <juli@incana.org>
+;;; Copyright © 2023 Hartmut Goebel <h.goebel@crazy-compilers.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -119,6 +120,7 @@ 
   #:use-module (gnu packages python-xyz)
   #:use-module (gnu packages pulseaudio)
   #:use-module (gnu packages readline)
+  #:use-module (gnu packages ruby)
   #:use-module (gnu packages rsync)
   #:use-module (gnu packages selinux)
   #:use-module (gnu packages sdl)
@@ -138,6 +140,7 @@ 
   #:use-module (guix build-system go)
   #:use-module (guix build-system meson)
   #:use-module (guix build-system python)
+  #:use-module (guix build-system ruby)
   #:use-module (guix build-system trivial)
   #:use-module (guix download)
   #:use-module (guix git-download)
@@ -2164,6 +2167,40 @@  the image.
 @end enumerate")
     (license license:asl2.0)))
 
+(define-public ruby-vagrant-spec
+  (package
+    (name "ruby-vagrant-spec")
+    (version "0.0.6")
+    (source (origin
+              (method url-fetch)
+              (uri (rubygems-uri "vagrant_spec" version))
+              (sha256
+               (base32
+                "1bkzz3mj7kzsv6k0ii8w31cgkpiqw3wvmvv2c6rknsavqqnagb4g"))))
+    (build-system ruby-build-system)
+    ;; (native-inputs (list ruby-rubocop ruby-vagrant-spec-helper-basic))
+    (propagated-inputs (list ruby-coveralls ruby-serverspec ruby-dep))
+    (arguments
+     (list
+      #:tests? #f  ;; tests require vagrant
+      ;; target 'test' includes 'cops' and running some ansible-playbook
+      #:test-target "unit"
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'unpack 'patch
+            (lambda _
+              (substitute* "Rakefile"
+                (("Bundler::GemHelper") "require 'bundler'\nBundler::GemHelper"))))
+          (add-before 'check 'prepare-check
+            (lambda _
+              (setenv "HOME" "/tmp"))))))
+    (synopsis "Specification and tests for Vagrant")
+    (description "@code{vagrant-spec} is a both a specification of how Vagrant
+and its various components should behave as well as a library of testing
+helpers that let you write your own unit and acceptance tests for Vagrant.")
+    (home-page "https://github.com/hashicorp/vagrant-spec")
+    (license license:mpl2.0)))
+
 (define-public python-vagrant
   (package
     (name "python-vagrant")