Upgrade to Ruby 3.4.0 (4d8c793bc3)
This commit is contained in:
parent
23ac0c148a
commit
f6d8680cd7
3 changed files with 13 additions and 129 deletions
|
|
@ -12,7 +12,7 @@ diff --git a/common.mk b/common.mk
|
|||
index d55d1788aa..73755f6ccd 100644
|
||||
--- a/common.mk
|
||||
+++ b/common.mk
|
||||
@@ -1649,8 +1649,6 @@ no-test-bundled-gems-spec:
|
||||
@@ -1652,8 +1652,6 @@ no-test-bundled-gems-spec:
|
||||
|
||||
test-syntax-suggest:
|
||||
|
||||
|
|
|
|||
29
ruby.spec
29
ruby.spec
|
|
@ -10,7 +10,7 @@
|
|||
%dnl %global milestone preview2
|
||||
|
||||
# Keep the revision enabled for pre-releases from GIT.
|
||||
%global revision 0f75ac8380
|
||||
%global revision 4d8c793bc3
|
||||
|
||||
%global ruby_archive %{name}-%{ruby_version}
|
||||
|
||||
|
|
@ -114,7 +114,7 @@
|
|||
%global irb_version 1.14.1
|
||||
%global json_version 2.8.2
|
||||
%global psych_version 5.2.0
|
||||
%global rdoc_version 6.7.0
|
||||
%global rdoc_version 6.8.1
|
||||
|
||||
# Bundled gems.
|
||||
%global abbrev_version 0.1.2
|
||||
|
|
@ -130,11 +130,11 @@
|
|||
%global net_smtp_version 0.5.0
|
||||
%global nkf_version 0.2.0
|
||||
%global matrix_version 0.4.2
|
||||
%global minitest_version 5.25.1
|
||||
%global mutex_m_version 0.2.0
|
||||
%global minitest_version 5.25.2
|
||||
%global mutex_m_version 0.3.0
|
||||
%global observer_version 0.1.2
|
||||
%global power_assert_version 2.0.4
|
||||
%global prime_version 0.1.2
|
||||
%global prime_version 0.1.3
|
||||
%global racc_version 1.8.1
|
||||
%global rake_version 13.2.1
|
||||
%global rbs_version 3.6.1
|
||||
|
|
@ -284,10 +284,6 @@ Patch6: ruby-2.7.0-Initialize-ABRT-hook.patch
|
|||
# Disable syntax_suggest test suite, which tries to download its dependencies.
|
||||
# https://bugs.ruby-lang.org/issues/19297
|
||||
Patch9: ruby-3.3.0-Disable-syntax-suggest-test-case.patch
|
||||
# Fix documentation generation for gems.
|
||||
# https://bugs.ruby-lang.org/issues/20862
|
||||
# https://github.com/ruby/rdoc/pull/1200
|
||||
Patch10: rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch
|
||||
|
||||
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
|
||||
%{?with_rubypick:Suggests: rubypick}
|
||||
|
|
@ -780,7 +776,6 @@ analysis result in RBS format, a standard type description format for Ruby
|
|||
%patch 4 -p1
|
||||
%patch 6 -p1
|
||||
%patch 9 -p1
|
||||
%patch 10 -p1
|
||||
|
||||
# Provide an example of usage of the tapset:
|
||||
cp -a %{SOURCE3} .
|
||||
|
|
@ -1617,12 +1612,12 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \
|
|||
|
||||
# mutex_m
|
||||
%dir %{gem_instdir mutex_m}
|
||||
%license %{gem_instdir mutex_m}/LICENSE.txt
|
||||
%license %{gem_instdir mutex_m}/BSDL
|
||||
%license %{gem_instdir mutex_m}/COPYING
|
||||
%{gem_libdir mutex_m}
|
||||
%{gem_instdir mutex_m}/sig
|
||||
%{gem_spec mutex_m}
|
||||
%{gem_instdir mutex_m}/Gemfile
|
||||
%doc %{gem_instdir mutex_m}/README.md
|
||||
%{gem_instdir mutex_m}/Rakefile
|
||||
|
||||
# net-ftp
|
||||
%dir %{gem_instdir net-ftp}
|
||||
|
|
@ -1690,12 +1685,12 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \
|
|||
|
||||
# prime
|
||||
%dir %{gem_instdir prime}
|
||||
%{gem_instdir prime}/Gemfile
|
||||
%license %{gem_instdir prime}/LICENSE.txt
|
||||
%license %{gem_instdir prime}/BSDL
|
||||
%license %{gem_instdir prime}/COPYING
|
||||
%doc %{gem_instdir prime}/README.md
|
||||
%{gem_instdir prime}/Rakefile
|
||||
%{gem_instdir prime}/bin
|
||||
%{gem_libdir prime}
|
||||
%{gem_instdir prime}/sig
|
||||
%{gem_spec prime}
|
||||
|
||||
# rdbg
|
||||
|
|
@ -1874,7 +1869,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \
|
|||
|
||||
%changelog
|
||||
* Thu Dec 19 2024 Vít Ondruch <vondruch@redhat.com> - 3.4.0-18
|
||||
- Upgrade to Ruby 3.4.0 (0f75ac8380)
|
||||
- Upgrade to Ruby 3.4.0 (4d8c793bc3)
|
||||
|
||||
* Mon Dec 16 2024 Jun Aruga <jaruga@redhat.com> - 3.3.6-18
|
||||
- Fix Ruby OpenSSL to respect crypto-policies TLS minimal version.
|
||||
|
|
|
|||
|
|
@ -1,111 +0,0 @@
|
|||
From 34db821add89ba7dd1e2ed64b7f636e9b6a9261a Mon Sep 17 00:00:00 2001
|
||||
From: Stan Lo <stan.lo@shopify.com>
|
||||
Date: Fri, 8 Nov 2024 09:43:28 -0600
|
||||
Subject: [PATCH] Extract excerpt from raw pages correctly
|
||||
|
||||
Fixes https://bugs.ruby-lang.org/issues/20862
|
||||
---
|
||||
lib/rdoc/generator/darkfish.rb | 14 ++++++-
|
||||
test/rdoc/test_rdoc_generator_darkfish.rb | 50 ++++++++++++++++++++++-
|
||||
2 files changed, 61 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/lib/rdoc/generator/darkfish.rb b/lib/rdoc/generator/darkfish.rb
|
||||
index 25ade1e9f1..08f2b85e3b 100644
|
||||
--- a/lib/rdoc/generator/darkfish.rb
|
||||
+++ b/lib/rdoc/generator/darkfish.rb
|
||||
@@ -782,7 +782,19 @@ def template_for file, page = true, klass = ERB
|
||||
|
||||
# Returns an excerpt of the content for usage in meta description tags
|
||||
def excerpt(content)
|
||||
- text = content.is_a?(RDoc::Comment) ? content.text : content
|
||||
+ text = case content
|
||||
+ when RDoc::Comment
|
||||
+ content.text
|
||||
+ when RDoc::Markup::Document
|
||||
+ # This case is for page files that are not markdown nor rdoc
|
||||
+ # We convert them to markdown for now as it's easier to extract the text
|
||||
+ formatter = RDoc::Markup::ToMarkdown.new
|
||||
+ formatter.start_accepting
|
||||
+ formatter.accept_document(content)
|
||||
+ formatter.end_accepting
|
||||
+ else
|
||||
+ content
|
||||
+ end
|
||||
|
||||
# Match from a capital letter to the first period, discarding any links, so
|
||||
# that we don't end up matching badges in the README
|
||||
diff --git a/test/rdoc/test_rdoc_generator_darkfish.rb b/test/rdoc/test_rdoc_generator_darkfish.rb
|
||||
index f6c0a1e1cf..0a9be7e4ee 100644
|
||||
--- a/test/rdoc/test_rdoc_generator_darkfish.rb
|
||||
+++ b/test/rdoc/test_rdoc_generator_darkfish.rb
|
||||
@@ -1,7 +1,7 @@
|
||||
# frozen_string_literal: true
|
||||
require_relative 'helper'
|
||||
|
||||
-class TestRDocGeneratorDarkfish < RDoc::TestCase
|
||||
+class RDocGeneratorDarkfishTest < RDoc::TestCase
|
||||
|
||||
def setup
|
||||
super
|
||||
@@ -348,7 +348,7 @@ def test_meta_tags_for_classes
|
||||
)
|
||||
end
|
||||
|
||||
- def test_meta_tags_for_pages
|
||||
+ def test_meta_tags_for_rdoc_files
|
||||
top_level = @store.add_file("CONTRIBUTING.rdoc", parser: RDoc::Parser::Simple)
|
||||
top_level.comment = <<~RDOC
|
||||
= Contributing
|
||||
@@ -367,6 +367,52 @@ def test_meta_tags_for_pages
|
||||
)
|
||||
end
|
||||
|
||||
+ def test_meta_tags_for_markdown_files
|
||||
+ top_level = @store.add_file("MyPage.md", parser: RDoc::Parser::Markdown)
|
||||
+ top_level.comment = <<~MARKDOWN
|
||||
+ # MyPage
|
||||
+
|
||||
+ This is a comment
|
||||
+ MARKDOWN
|
||||
+
|
||||
+ @g.generate
|
||||
+
|
||||
+ content = File.binread("MyPage_md.html")
|
||||
+ assert_include(content, '<meta name="keywords" content="ruby,documentation,MyPage">')
|
||||
+ assert_include(
|
||||
+ content,
|
||||
+ '<meta name="description" content="MyPage: # MyPage This is a comment">',
|
||||
+ )
|
||||
+ end
|
||||
+
|
||||
+ def test_meta_tags_for_raw_pages
|
||||
+ top_level = @store.add_file("MyPage", parser: RDoc::Parser::Simple)
|
||||
+ top_level.comment = RDoc::Markup::Document.new(RDoc::Markup::Paragraph.new('this is a comment'))
|
||||
+
|
||||
+ @g.generate
|
||||
+
|
||||
+ content = File.binread("MyPage.html")
|
||||
+ assert_include(content, '<meta name="keywords" content="ruby,documentation,MyPage">')
|
||||
+ assert_include(
|
||||
+ content,
|
||||
+ '<meta name="description" content="MyPage: this is a comment ">',
|
||||
+ )
|
||||
+ end
|
||||
+
|
||||
+ def test_meta_tags_for_empty_document
|
||||
+ top_level = @store.add_file("MyPage", parser: RDoc::Parser::Simple)
|
||||
+ top_level.comment = RDoc::Markup::Document.new
|
||||
+
|
||||
+ @g.generate
|
||||
+
|
||||
+ content = File.binread("MyPage.html")
|
||||
+ assert_include(content, '<meta name="keywords" content="ruby,documentation,MyPage">')
|
||||
+ assert_include(
|
||||
+ content,
|
||||
+ '<meta name="description" content="MyPage: ">',
|
||||
+ )
|
||||
+ end
|
||||
+
|
||||
##
|
||||
# Asserts that +filename+ has a link count greater than 1 if hard links to
|
||||
# @tmpdir are supported.
|
||||
Loading…
Add table
Add a link
Reference in a new issue