| |
@@ -1,29 +1,44 @@
|
| |
%global gem_name sinatra
|
| |
|
| |
%bcond_with bootstrap
|
| |
+ %bcond_without tilt_integration_tests
|
| |
|
| |
Name: rubygem-%{gem_name}
|
| |
- Version: 2.0.8.1
|
| |
- Release: 4%{?dist}
|
| |
+ Version: 2.1.0
|
| |
+ Release: 1%{?dist}
|
| |
Summary: Ruby-based web application framework
|
| |
License: MIT
|
| |
URL: http://sinatrarb.com/
|
| |
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
| |
# git clone https://github.com/sinatra/sinatra.git && cd sinatra
|
| |
- # git archive -v -o sinatra-2.0.8.1-test.tar.gz v2.0.8.1 test/
|
| |
+ # git archive -v -o sinatra-2.1.0-test.tar.gz v2.1.0 test/
|
| |
Source1: %{gem_name}-%{version}-test.tar.gz
|
| |
- # Fix test failure due to Rack 2.2.2 incompatibility.
|
| |
- # https://github.com/sinatra/sinatra/pull/1605
|
| |
- Patch0: rubygem-sinatra-2.0.8.1-Fix-failing-tests.patch
|
| |
BuildRequires: ruby(release)
|
| |
BuildRequires: rubygems-devel
|
| |
BuildRequires: ruby >= 2.2.0
|
| |
%if %{without bootstrap}
|
| |
BuildRequires: rubygem(rack-protection) = %{version}
|
| |
- BuildRequires: rubygem(tilt)
|
| |
+ BuildRequires: rubygem(builder)
|
| |
+ BuildRequires: rubygem(coffee-script)
|
| |
+ BuildRequires: rubygem(creole)
|
| |
+ BuildRequires: rubygem(liquid)
|
| |
BuildRequires: rubygem(mustermann)
|
| |
BuildRequires: rubygem(rack-test)
|
| |
BuildRequires: rubygem(minitest) > 5
|
| |
+ BuildRequires: rubygem(redcarpet)
|
| |
+ # Tilt is actually required from base_test
|
| |
+ BuildRequires: rubygem(tilt)
|
| |
+ BuildRequires: nodejs
|
| |
+ %if %{with tilt_integration_tests}
|
| |
+ BuildRequires: rubygem(asciidoctor)
|
| |
+ BuildRequires: rubygem(rdiscount)
|
| |
+ BuildRequires: rubygem(kramdown)
|
| |
+ BuildRequires: rubygem(nokogiri)
|
| |
+ BuildRequires: rubygem(erubi)
|
| |
+ BuildRequires: rubygem(haml)
|
| |
+ BuildRequires: rubygem(slim)
|
| |
+ BuildRequires: rubygem(sass)
|
| |
+ %endif
|
| |
%endif
|
| |
Epoch: 1
|
| |
BuildArch: noarch
|
| |
@@ -44,10 +59,6 @@
|
| |
%prep
|
| |
%setup -q -n %{gem_name}-%{version} -b 1
|
| |
|
| |
- pushd %{_builddir}
|
| |
- %patch0 -p1
|
| |
- popd
|
| |
-
|
| |
%build
|
| |
# Create the gem as gem install only works on a gem file
|
| |
gem build ../%{gem_name}-%{version}.gemspec
|
| |
@@ -77,6 +88,21 @@
|
| |
# We can't do integration test
|
| |
# because we don't ship sinatra-contrib including Sinatra::Runner.
|
| |
mv test/integration_test.rb{,.disabled}
|
| |
+ mv test/integration_async_test.rb{,.disabled}
|
| |
+
|
| |
+ %if %{without tilt_integration_tests}
|
| |
+ mv test/asciidoctor_test.rb{,.disabled}
|
| |
+ %endif
|
| |
+
|
| |
+ # False positive: inline layouts are rendered differently than expected
|
| |
+ #-"<h1>THIS. IS. <EM>SPARTA</EM></h1>
|
| |
+ #+# encoding: ASCII-8BIT
|
| |
+ #+# valid: true
|
| |
+ #+"<h1>THIS. IS. <EM>SPARTA</EM>
|
| |
+ #+</h1>
|
| |
+ sed -i '/ layouts" do/ a \
|
| |
+ skip' test/haml_test.rb
|
| |
+
|
| |
# TODO: Is it worth of testing all the possible template engines integration?
|
| |
ruby -e 'Dir.glob "./test/*_test.rb", &method(:require)'
|
| |
popd
|
| |
@@ -105,6 +131,11 @@
|
| |
%{gem_instdir}/sinatra.gemspec
|
| |
|
| |
%changelog
|
| |
+ * Mon Aug 02 2021 Pavel Valena <pvalena@redhat.com> - 1:2.1.0-1
|
| |
+ - Update to sinatra 2.1.0.
|
| |
+ Resolves: rhbz#1875978
|
| |
+ Resolves: rhbz#1970606
|
| |
+
|
| |
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1:2.0.8.1-4
|
| |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
| |
|
| |
To have latest sinatra gem in Fedora.
Koji scratch-build:
https://koji.fedoraproject.org/koji/taskinfo?taskID=73131344
https://kojipkgs.fedoraproject.org/work/tasks/8371/73138371/build.log (enabled tests)
Copr build:
https://copr.fedorainfracloud.org/coprs/build/2356650
Checks:
with bootstrap)Test log: https://git.io/JBQig
gem2rpm diff: https://git.io/JBQi2