3
5
Fork 0
mirror of git://git.savannah.gnu.org/guix.git synced 2023-12-14 03:33:07 +01:00

gnu: ruby-yard: Update to 0.9.5-1.d816482a.

* gnu/packages/ruby.scm (ruby-yard): Update to 0.9.5-1.d816482a.
[source]: Update source URL.
[arguments]: Remove unneeded substitutions.  Change test target.
* gnu/packages/patches/ruby-yard-fix-skip-of-markdown-tests.patch (New
file)
* gnu/local.mk (dist_patch_DATA): Add it.
This commit is contained in:
Ben Woodcroft 2016-11-08 09:39:47 +10:00
parent 7c45670b32
commit e2bb2e1780
No known key found for this signature in database
GPG key ID: E44DCCD146E0CCF4
3 changed files with 54 additions and 34 deletions

View file

@ -7,6 +7,7 @@
# Copyright © 2016 Kei Kebreau <kei@openmailbox.org> # Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
# Copyright © 2016 Adonay "adfeno" Felipe Nogueira <https://libreplanet.org/wiki/User:Adfeno> <adfeno@openmailbox.org> # Copyright © 2016 Adonay "adfeno" Felipe Nogueira <https://libreplanet.org/wiki/User:Adfeno> <adfeno@openmailbox.org>
# Copyright © 2016 Ricardo Wurmus <rekado@elephly.net> # Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
# Copyright © 2016 Ben Woodcroft <donttrustben@gmail.com>
# #
# This file is part of GNU Guix. # This file is part of GNU Guix.
# #
@ -841,6 +842,7 @@ dist_patch_DATA = \
%D%/packages/patches/ruby-rack-ignore-failing-test.patch \ %D%/packages/patches/ruby-rack-ignore-failing-test.patch \
%D%/packages/patches/ruby-symlinkfix.patch \ %D%/packages/patches/ruby-symlinkfix.patch \
%D%/packages/patches/ruby-tzinfo-data-ignore-broken-test.patch\ %D%/packages/patches/ruby-tzinfo-data-ignore-broken-test.patch\
%D%/packages/patches/ruby-yard-fix-skip-of-markdown-tests.patch \
%D%/packages/patches/sed-hurd-path-max.patch \ %D%/packages/patches/sed-hurd-path-max.patch \
%D%/packages/patches/scheme48-tests.patch \ %D%/packages/patches/scheme48-tests.patch \
%D%/packages/patches/scotch-test-threading.patch \ %D%/packages/patches/scotch-test-threading.patch \

View file

@ -0,0 +1,17 @@
The tests currently fail due to use of 'skip' rather than 'pending' to skip a
test usually not skipped by upstream. This patch has been proposed upstream
at https://github.com/lsegal/yard/pull/1033
diff --git a/spec/templates/helpers/html_helper_spec.rb b/spec/templates/helpers/html_helper_spec.rb
index 84624c3..9c4fc2b 100644
--- a/spec/templates/helpers/html_helper_spec.rb
+++ b/spec/templates/helpers/html_helper_spec.rb
@@ -184,7 +184,7 @@ describe YARD::Templates::Helpers::HtmlHelper do
it "creates tables (markdown specific)" do
log.enter_level(Logger::FATAL) do
unless markup_class(:markdown).to_s == "RedcarpetCompat"
- skip "This test depends on a markdown engine that supports tables"
+ pending "This test depends on a markdown engine that supports tables"
end
end

View file

@ -3047,43 +3047,44 @@ features such as filtering and fine grained logging.")
(license license:expat))) (license license:expat)))
(define-public ruby-yard (define-public ruby-yard
(package ;; Use git reference because gem is >100 commits out of date and the tests
(name "ruby-yard") ;; do not pass with the released gem.
(version "0.8.7.6") (let ((commit "d816482a0d4850506c3bcccc9434550c536c28c6"))
(source (package
(origin (name "ruby-yard")
(method url-fetch) (version (string-append "0.9.5-1." (string-take commit 8)))
(uri (rubygems-uri "yard" version)) (source
(sha256 (origin
(base32 (method git-fetch)
"1dj6ibc0qqvmb5a5r5kk0vhr04mnrz9b26gnfrs5p8jgp620i89x")))) (uri (git-reference
(build-system ruby-build-system) (url "https://github.com/lsegal/yard.git")
(arguments (commit commit)))
`(#:test-target "specs" (file-name (string-append name "-" version "-checkout"))
#:phases (sha256
(modify-phases %standard-phases (base32
(add-before 'check 'set-HOME-and-disable-failing-test "1j16c85x22if7y0fzi3c900p9wzkx2riq1y7vsj92a0zvwsxai4i"))
(lambda _ (patches (search-patches "ruby-yard-fix-skip-of-markdown-tests.patch"))))
;; $HOME needs to be set to somewhere writeable for tests to run (build-system ruby-build-system)
(setenv "HOME" "/tmp") (arguments
;; Disable tests which fails on Ruby 2.3. See `(#:test-target "spec"
;; https://github.com/lsegal/yard/issues/927 #:phases
(substitute* "spec/parser/ruby/ruby_parser_spec.rb" (modify-phases %standard-phases
(("comment.type.should == :comment") "") (add-before 'check 'set-HOME-and-disable-failing-test
(("comment.docstring_hash_flag.should be_true") "") (lambda _
(("comment.docstring.strip.should == .*") "")) ;; $HOME needs to be set to somewhere writeable for tests to run
#t))))) (setenv "HOME" "/tmp")
(native-inputs #t)))))
`(("ruby-rspec" ,ruby-rspec-2) (native-inputs
("ruby-rack" ,ruby-rack))) `(("ruby-rspec" ,ruby-rspec-2)
(synopsis "Documentation generation tool for Ruby") ("ruby-rack" ,ruby-rack)))
(description (synopsis "Documentation generation tool for Ruby")
"YARD is a documentation generation tool for the Ruby programming (description
"YARD is a documentation generation tool for the Ruby programming
language. It enables the user to generate consistent, usable documentation language. It enables the user to generate consistent, usable documentation
that can be exported to a number of formats very easily, and also supports that can be exported to a number of formats very easily, and also supports
extending for custom Ruby constructs such as custom class level definitions.") extending for custom Ruby constructs such as custom class level definitions.")
(home-page "http://yardoc.org") (home-page "http://yardoc.org")
(license license:expat))) (license license:expat))))
(define-public ruby-clap (define-public ruby-clap
(package (package